cartopy icon indicating copy to clipboard operation
cartopy copied to clipboard

set_extent over 360 longitudes

Open qdnse opened this issue 4 years ago • 3 comments

Description

For a routing purpose, i need to plot a route which do more than a world tour (360+ in longitudes). But, you can't set an extent more than -180/180 longitude.

Is there any way to create a map similar to the next one, using the set_extent method like this : set_extent([-180, 540, -90, 90]) map

Thanks for the amazing work done!

qdnse avatar Aug 13 '20 07:08 qdnse

I don't know that any of the projections are set up to even handle that--that's PROJ limitation. Everything I can think of is going to map a longitude of 470 to the same location as longitude 110.

The best I can come up with is to plot without a projection (straight matplotlib) and plot two copies of the map information, with one having all longitudes offset by 360.

dopplershift avatar Aug 14 '20 17:08 dopplershift

@qdnse did you ever work out a solution to this problem? I'm working on some oceanographic maps, and it would be really useful to have a modest degree of overlap at the left and right edges of the plot.

mdaeron avatar May 10 '24 13:05 mdaeron

This feels like it should be possible now if support for +over is added, per: https://proj.org/en/9.4/usage/projections.html#longitude-wrapping

lgolston avatar May 11 '24 04:05 lgolston