matplotlib flip bar chart on y axis code example Example: invert y axis python plt.gca().invert_yaxis()