diff --git a/galleries/examples/units/bar_unit_demo.py b/galleries/examples/units/bar_unit_demo.py index 18e2c00b699e..05e0dfad902d 100644 --- a/galleries/examples/units/bar_unit_demo.py +++ b/galleries/examples/units/bar_unit_demo.py @@ -22,6 +22,7 @@ tea_std = [2*cm, 1*cm, 1*cm, 4*cm, 2*cm] fig, ax = plt.subplots() +ax.yaxis.set_units(inch) ind = np.arange(N) # the x locations for the groups width = 0.35 # the width of the bars @@ -36,7 +37,6 @@ ax.set_xticks(ind + width / 2, labels=['G1', 'G2', 'G3', 'G4', 'G5']) ax.legend() -ax.yaxis.set_units(inch) ax.autoscale_view() plt.show()