robustified _from_data. fixed test change