[R] Create a heat map with German postal codes

Jim Lemon drjimlemon at gmail.com
Sat Feb 7 07:12:38 CET 2015


Hi Paul,
Have you seen this site?

http://blog.oraylis.de/2010/05/german-map-spatial-data-for-plz-postal-code-regions/

This seems to have the solution you want, and perhaps some useful
stuff about aggregating postal zones. For one off maps, I usually just
look at par("usr") to get the current plot limits and then trial and
eyeball the limits for the area I want.

Jim


On Sat, Feb 7, 2015 at 9:37 AM, Paul Tremblay <paulhtremblay at gmail.com> wrote:
> Hi,
>
> I am tasked with making a map of German postal codes for a few major cities
> in Germany. Each postal code will have a differnt color, depending on a
> metric. For simplicity, let's just use population density.
>
> This is what I have achieved so far for London (which I used as an
> example). I have been able to create a base map using the tutorials. I was
> able to import a shapefile of postal codes and display that on the map. I
> was able to create points on the map.
>
> What I am not able to do is color in each postal code according to density.
> The other problem I have is with actually creating a map that zooms in on
> the right area. I know you can limit the area with xlim and ylim, but I
> can't figure out sensible values for eacy of these parameters.
>
> I have not found a shapefile yet for German postal codes.
>
> Last, should I use worldmaps, or a more recent package such as ggmap or
> rworldmap? I have seen that worldmaps is very outdated.
>
> We have commercial software such as Tableau and Map Point (since
> discontinued) floating around here. Both of these software automatically
> map districts for US and London postal codes. However, I would like to use
> an open source solution if for no other reason than these commercial
> software might not work for other regions, and R seems better to extend for
> special cases.
>
> Thanks!
>
> Paul
>
>         [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list