-
Notifications
You must be signed in to change notification settings - Fork 370
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pcolormesh no longer wraps around #1997
Comments
Interestingly if you do |
Thank you for the quick fix! Feels like I keep throwing "edge" cases at you.
This also gives me an idea how to create a work around for now (use 0..360 instead of -180..180). (Definitely not the same problem but if you try different crs with the above code (e.g. import cartopy.crs as ccrs
import matplotlib.pyplot as plt
import numpy as np
lon = np.arange(-180, 151, 30)
lat = np.arange(75, -76, -30)
data = np.ones(shape=lat.shape + lon.shape)
f, ax = plt.subplots(1, 1, subplot_kw=dict(projection=ccrs.EckertIII()))
ax.pcolormesh(
lon_edges,
lat_edges,
data,
transform=ccrs.PlateCarree(),
cmap="Reds",
ec="0.3",
lw=0.5,
)
ax.coastlines()
ax.set_global() |
I think that is to be expected here and I'm not sure how easy it would be to fix. I think what is happening is that the |
Thanks, makes sense. Just something I saw trying out different projections. |
Description
pcolormesh no longer draws the "other half" of gridpoints that have their center at the edge of the maps - see the example and figure. This may very well be an 'indended' consequence of #1646 but I thought I report it anyway.
This used to work in older versions of cartopy/ matplotlib (e.g. cartopy=0.19 and matplotlib=3.4)
Code to reproduce
Full environment definition
Operating system
Linux
Cartopy version
0.20.2
matplotlib.version
3.5.1
conda list
pip list
The text was updated successfully, but these errors were encountered: