Closed
Description
I was trying to use the recent axes bxp()
functionality with a list of statistics dictionaries. My dictionaries include only ['whislo', 'q1', 'med', 'q3', 'whishi']
.
The documentation mentions that fliers
is an optional key so long as showfliers=False
. However the bxp function always accesses the fliers
key, and accordingly throws a KeyError
. The relevant access is as follows:
lib/matplotlib/axes/_axes.py#L3722-L3727
for pos, width, stats in zip(positions, widths, bxpstats):
# try to find a new label
datalabels.append(stats.get('label', pos))
# fliers coords
flier_x = np.ones(len(stats['fliers'])) * pos
flier_y = stats['fliers']