[R-sig-Geo] seamless maps

Hans-Jörg Bibiko bibiko at eva.mpg.de
Thu Jan 8 15:29:10 CET 2009

On 08.01.2009, at 15:05, Roger Bivand wrote:

> On Thu, 8 Jan 2009, Matt Oliver wrote:
>> Hans,
>> Take a look at the proj4 package, specifically project()
> Or rather rgdal, which is a fully featured implementation with a  
> proper interface to the PROJ.4 library. Unfortunately, there does  
> not seem to be a way of shifting the prime meridian in a helpful way  
> - and the original question was not about projection, but about  
> joining +180 to -180, which is obvious in spherical but not in  
> planar terms. rgdal provides methods for projection and datum  
> transformation for objects defined in the sp package, as well as for  
> projection of matrices of coordinates.

Thanks! I'm just playing with it.
Actually I do need the polygons as well.

A VERY quick&dirty&crude solution would be to pack the wrld_simpl  
polygons three times in a new SpatialPolygons object:

-the original one from -180 to 180
-a transformed one from 180 to 540
-a transformed one from -540 to -180

then by specifying xlim only one should be able to center the map for  
any longitude (to get only that clipping).
But I know it's a crude approach and then if one wants to put  
additional points/lines/etc. on it one has to treble them as well.

But anyway, thanks so much for the hints. If I found a way I'll post it.


Hans-Joerg Bibiko
Max Planck Institute for Evolutionary Anthropology
Department of Linguistics
Deutscher Platz 6     phone:   +49 (0) 341 3550 341
D-04103 Leipzig       fax:     +49 (0) 341 3550 333
Germany               e-mail:  bibiko at eva.mpg.de

More information about the R-sig-Geo mailing list