This is a pretty nit-picky thing, but I'm using a skew-T axes between two other non-skewed axes, and matplotlib's tight_layout() gets a bit confused in this situation. This code:
from metpy.plots import SkewT
import matplotlib.pyplot as plt
fig = plt.figure(facecolor='w', dpi=150)
plt.subplot(131)
SkewT(fig=fig, subplot=132)
plt.subplot(133)
plt.tight_layout()
plt.show()
produces this image:
There's a lot more space between the subplots than I would expect for tight_layout(), and the exact amount of space depends on the x limits on the skew-T axes. Setting plt.xlim(0, 50) looks more reasonable, and plt.xlim(-40, 0) looks less reasonable. As a workaround, I can move the skew-T axes to the right subplot, which produces a more reasonable-looking subplot spacing (but still not quite what I'd expect from non-skewed axes).
I am on Mac OS X 10.14.6, running Python 3.6.7, MetPy v0.12.1, and Matplotlib v3.0.2.
Well, thanks for reporting. Any chance you can try this with a more recent version of matplotlib? We fixed some aspect ratio things, but it relies on Matplotlib >= 3.2 (3.3 just dropped).
This is a pretty nit-picky thing, but I'm using a skew-T axes between two other non-skewed axes, and matplotlib's tight_layout() gets a bit confused in this situation. This code:
produces this image:
There's a lot more space between the subplots than I would expect for tight_layout(), and the exact amount of space depends on the x limits on the skew-T axes. Setting
plt.xlim(0, 50)
looks more reasonable, andplt.xlim(-40, 0)
looks less reasonable. As a workaround, I can move the skew-T axes to the right subplot, which produces a more reasonable-looking subplot spacing (but still not quite what I'd expect from non-skewed axes).I am on Mac OS X 10.14.6, running Python 3.6.7, MetPy v0.12.1, and Matplotlib v3.0.2.