How do I extend the margin at the bottom of a figure in Matplotlib?
问题 The following screenshot shows my x-axis. I added some labels and rotated them by 90 degrees in order to better read them. However, pyplot truncates the bottom such that I'm not able to completely read the labels. How do I extend the bottom margin in order to see the complete labels? 回答1: Two retroactive ways: fig, ax = plt.subplots() # ... fig.tight_layout() Or fig.subplots_adjust(bottom=0.2) # or whatever Here's a subplots_adjust example: http://matplotlib.org/examples/pylab_examples