there is something missing in my understanding of groupby.boxplot()
.
I have a dataFrame DF
with dates' and
values` like below :
dates values
0 2016-10-20 18:19:15 20.8
1 2016-10-20 18:20:15 21.1
2 2016-10-20 18:21:15 21.3
3 2016-10-20 18:22:15 21.6
4 2016-10-20 18:23:15 21.8
5 2016-10-20 18:24:15 22.1
...
...
1176468 2018-09-18 03:17:19 19.7
1176469 2018-09-18 03:18:19 20.0
1176470 2018-09-18 03:19:19 20.2
1176471 2018-09-18 03:20:19 20.4
1176472 2018-09-18 03:21:19 20.6
I grouped DF :
groups = DF.groupby(pd.Grouper(freq='6M', key='dates'))
And then I want a boxplot :
box = groups.boxplot(subplots=False)
The boxplots are fine, but I would like to customized the xaxis "dates" position formats like it is possible with pyplot.boxplot
assigning position = mdates.date2num()
and using set_major_locator(mdates.YearLocator())
for example.
Does someone know How to do that with groupby.boxplot()
?