I can't figure out how to get transform to work with plt.subplots. Since most people are using this function to create their axes these days, I think it'd be useful to patch this function in the same way that plt.subplot is patched...
Cartopy doesn't patch plt.subplot, for that one matplotlib allows the projection keyword argument, which is what Cartopy uses.
To use plt.subplots do:
import matplotlib.pyplot as plt
import cartopy.crs as ccrs
proj = ccrs.Geostationary()
fig, axes = plt.subplots(2, 2, subplot_kw=dict(projection=proj)))
I'm not saying it's pretty, but it's really a matplotlib problem, not really a CartoPy problem unless cartopy really wants to get in the business of overwriting matplotlib API.
oh hoh - that's nifty, good to know. I'm gonna close this issue and suggest to add an example that shows this off in my other issue ;-) #899
Most helpful comment
Cartopy doesn't patch
plt.subplot, for that one matplotlib allows theprojectionkeyword argument, which is what Cartopy uses.To use
plt.subplotsdo:I'm not saying it's pretty, but it's really a matplotlib problem, not really a CartoPy problem unless cartopy really wants to get in the business of overwriting matplotlib API.