|
From: Eric B. <eri...@gm...> - 2009-10-15 20:02:52
|
I'm using basemap to plot a dataset* that has longitude values like so: lon = [0, 2, 4, ..., 356, 358] I'd like to use Basemap.shiftgrid to transform the longitudes and data to the -180, 180 interval, but I get 'ValueError, cyclic point not included' since 360 isn't among the longitudes. Attached is a version of shiftgrid that attempts to handle the non-cyclic case. There are pseudo-unit-tests that demonstrate the cyclic and non-cyclic case for a 180 degree shift. Thanks, Eric *SST anomalies from http://nomads.ncdc.noaa.gov/thredds/dodsC/ersstv3Agg |