Closed
Description
For the following code:
rng = pd.date_range('1/1/2011', periods=200, freq='D')
rng = rng.tz_localize('UTC')
ts = pd.Series(cumsum(randn(len(rng))), index=rng)
the following resample:
ts.resample('m', how='mean')
works fine, but this one:
ts.resample('m', how={'Mean': 'mean', 'Std': 'std'})
fails with the error: TypeError: can't compare offset-naive and offset-aware datetimes
However if we choose other interval of resampling (e.g. daily or quarterly or weekly):
ts.resample('D', how={'Mean': 'mean', 'Std': 'std'})
or
ts.resample('Q', how={'Mean': 'mean', 'Std': 'std'})
there would be no error.
OS: OSX 10.8.3
python: 2.7.4
pandas: 0.11.0
Metadata
Metadata
Assignees
Labels
No labels