Skip to content

Instantly share code, notes, and snippets.

@jnmclarty
Last active August 29, 2015 14:16
Show Gist options
  • Save jnmclarty/aa56afde01e9fb7134b4 to your computer and use it in GitHub Desktop.
Save jnmclarty/aa56afde01e9fb7134b4 to your computer and use it in GitHub Desktop.
BoxPlot By Year
vsf['year'] = [d.year for d in vsf.index]
vsf[['contribution_room','year']].boxplot(rot=90,by='year')
yrs = [str(d.year) for d in vsf.resample('A').index]
sd = {y[2:] : vsf[y]['contribution_room'] for y in yrs}
pd.DataFrame(sd).boxplot(rot=90,return_type='axes')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment