I created a boxplot out of a pandas df by running the following:
ax = df1.boxplot(column=['data1'], by=['category'], grid=False, figsize=(6,5))
and the resulting boxplot came with:
- a default title (ie. grouped title): "Boxplot grouped by category" --> see yellow
- a subtitle (what would be the "usual" title for other graph types): "data1" --> see green
When I tried to change the grouped title by passing the title argument into the boxplot function, this didn't work (although it's worked for other chart types like barh)
ax = df1.boxplot(column=['data1'], by=['category'], grid=False, figsize=(6,5), title = 'my_title')
If we use the ax.set_title() approach as described here, it will change the boxplot subtitle but NOT the grouped title.
Please note that my question does not duplicate this one, as that post's solution will only affect the subtitle instead of the grouped title, and I'm looking for a change in the boxplot's grouped title