ref_url: http://deanla.com/dont_reinvent_pandas.html#Resample ref_name: DeanLa's Blog ---
Task: How many events happen each hour?
bad = df.copy()
bad['day'] = bad.index.date
bad['hour'] = bad.index.hour
(bad
.groupby(['day','hour'])
.count()
)
df.resample('H').count() # H is for Hour