Hi,
-----
I'm trying to make my first ever IRIS polar projection plot, but I can't seem to get it to work. I then found this example for projections
---------
import iris import iris.plot as iplt import cartopy.crs as ccrs import matplotlib.pyplot as plt fname = iris.sample_data_path('air_temp.pp') air_temp = iris.load_cube(fname) ax = plt.axes(projection=ccrs.Robinson(central_longitude=180)) iplt.contourf(air_temp) ax.coastlines() plt.show()
-----
and I get an error:
RuntimeError: Unidentified problem with geometry, linestring being re-added
I've then tried to modify this to polar projection, which is what I really want:
import iris import iris.plot as iplt import cartopy.crs as ccrs import matplotlib.pyplot as plt fname = iris.sample_data_path('air_temp.pp') air_temp = iris.load_cube(fname)
ax = plt.axes(projection=ccrs.NorthPolarStereo(central_longitude=0.0))
iplt.contourf(air_temp) ax.coastlines() plt.show()
-----
and then I don't get an error, but all I get is a completely blank image window - no map!
Clearly I'm doing something stupid - any hints?
Thanks,
Nick
(from: http://stackoverflow.com/questions/13766275/can-you-change-iris-cube-projections-in-cartopy)
ax.set_global()
# Northern Hemisphere from 23 degrees north:
ax.set_extent([-180, 180, 23, 90], crs=ccrs.PlateCarree())