1

I have a DataFrame for which

hub2['time'] = pd.to_datetime(hub2.timestamp)

works, but when I write

hub2 >> mutate(time=pd.to_datetime(X.timestamp))

with https://github.com/kieferk/dfply I get the error

Traceback (most recent call last): File "<input>", line 1, in <module> File "[...]/lib/python2.7/site-packages/pandas/util/decorators.py", line 91, in wrapper return func(*args, **kwargs) File "[...]/lib/python2.7/site-packages/pandas/tseries/tools.py", line 419, in to_datetime elif isinstance(arg, ABCSeries): File "[...]/lib/python2.7/site-packages/pandas/types/generic.py", line 9, in _check return getattr(inst, attr, '_typ') in comp TypeError: __nonzero__ should return bool or int, returned Call

Why is that?

www
  • 38,575
  • 12
  • 48
  • 84
Make42
  • 12,236
  • 24
  • 79
  • 155

0 Answers0