python - Axis bug on Pandas groupby boxplots -
the head of pandas dataframe , df
, shown below:
count1 count2 totalcount season 0 3 13 16 1 1 8 32 40 1 2 5 27 32 1 3 3 10 13 1 4 0 1 1 1
i'd create boxplots of count1
, count2
, , totalcount
, grouped season
(there 4 seasons) , have each set of box plots show on own subplot in single figure.
when 2 of columns, count1
, count2
, looks great.
df.boxplot(['count1', 'count2'], by='season')
but when add together totalcount
mix, axis limits go haywire.
df.boxplot(['count1', 'count2', 'totalcount'], by='season')
this happens irregardless of order of columns. realize there several ways around problem, much more convenient if worked properly.
am missing something? known bug in pandas? wasn't able find in first pass of pandas bug reports.
i'm using pandas 0.14.0 , matplotlib 1.3.1.
did tried upgrade pandas/matplotlib packages?
i'm using pandas 0.13.1 + matplotlib 1.2.1 , plot get:
in [31]: df out[34]: count1 count2 totalcount season 0 3 13 16 1 1 8 32 40 1 2 5 27 32 1 3 3 10 13 1 4 0 1 1 1 5 3 13 16 2 6 8 32 40 2 7 5 27 32 3 8 3 10 13 3 9 0 1 1 4 10 3 10 13 4 11 3 13 16 4 [12 rows x 4 columns]
python matplotlib pandas
No comments:
Post a Comment