There is a DataFrame 'modtso':
In [4]: modtso Out[4]: <class 'pandas.core.frame.DataFrame'> DatetimeIndex: 74006 entries, 2002-07-27 15:00:00 to 2010-12-31 22:58:08 Data columns: 0 74006 non-null values dtypes: float32(1) In [5]: modtso[1:10] Out[5]: 0 2002-07-27 16:01:53 9.336845 2002-07-27 16:58:08 9.337487 2002-07-27 18:00:00 9.343308 2002-07-27 19:01:53 9.364368 2002-07-27 19:58:08 9.389445 ...
Now I want to redo it as shown below:
a=modtso.resample('D',how='std')
it will throw an exception:
ValueError: Buffer dtype mismatch, expected 'float64_t' but got 'float'
what problem? how can i fix this? thanks
source share