[R-sig-Geo] Eurostat shapefiles & google maps offset

Patrick Brown patrick.brown at utoronto.ca
Fri Mar 24 15:42:35 CET 2017


Hello, you'll need to reproject either your shapefiles or the background
images.  The mapmisc package can get you background images in a specified
projection
https://journal.r-project.org/archive/2016-1/brown.pdf

p


> Message: 1
> Date: Wed, 22 Mar 2017 18:19:01 +0100
> From: Martin Zuba <martin.zuba at gmx.at>
> To: r-sig-geo at r-project.org
> Subject: [R-sig-Geo] Eurostat shapefiles & google maps offset
> Message-ID:
>         <CAG3rrX6XbtNo8B9oTa=5=Yu7pN3WAA9m+BNC=dXKssA2D_un6Q@
> mail.gmail.com>
> Content-Type: text/plain; charset="UTF-8"
>
> Dear list,
>
> I would like to plot shaded shapefiles with static google maps background
> images.
>
> I obtain the shapefiles from Eurostat, via the eurostat R package.
>
> I obtain the static google background images from using the get_map wrapper
> from the R package ggmap.
>
> My problem is that there seems to be an offset between those two coordinate
> systems. I know that the Eurostat files uss the coordinate reference system
> ETRS89 and google maps uses WSG84, which should be (almost) identical.
>
> However, google images and the shapefiles are somwhat off; and that offset
> is not constant, which indicates that there might be a problem related to
> projections.
>
>
> illustration:
> https://www.dropbox.com/s/34k2ace42ubjjek/eurostatVSgoogle.png?dl=0
>
> replication:
> https://www.dropbox.com/s/hhoc84lrmo42imf/niceEurostat.R?dl=0
>
>
> I welcome any suggestions.
>
> Best Regards,
>
> Martin Zuba
>
>         [[alternative HTML version deleted]]
>
>
>
> ------------------------------
>
> Subject: Digest Footer
>
> _______________________________________________
> R-sig-Geo mailing list
> R-sig-Geo at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>
> ------------------------------
>
> End of R-sig-Geo Digest, Vol 163, Issue 20
> ******************************************
>

	[[alternative HTML version deleted]]



More information about the R-sig-Geo mailing list