jvns/pandas-cookbook

Update to Chapter 6

Opened this issue · 0 comments

is_snowing.astype(float).resample('M', how=np.mean).plot(kind='bar')

FutureWarning: how in .resample() is deprecated
the new syntax is .resample(...)..apply()
if name == 'main':

The new way to write it is:
is_snowing.astype(float).resample('M').apply(np.mean).plot(kind='bar')

Thanks!