Hello,

I want to create side-by-side maps of similar attribute data in two different cities using a single legend.

To simply display side-by-side census block group boundary (non-thematic) maps for Minneapolis & Cleveland I do the following:

library(rgdal)
library(sp)
Minneapolis=readOGR("../Minneapolis/Census/2010/Census_BlockGroup_GEO/","tl_2010_27053_bg10")
Cleveland=readOGR("../Cleveland/Census/2010/Census_BlockGroup_GEO/","tl_2010_39035_bg10")
par(mfrow=c(1,2))
plot(Minneapolis)
plot(Cleveland)

I can display a single thematic map for a city using spplot as follows:

spplot(Minneapolis,"Thematic_Data_Column")

But, calling the function again for Cleveland just overwrites the window. I am unsure how to use spplot's layout tools with two different geographies. Most examples use a single geography and multiple attribute columns. Alternatively, is there a way to use "par" together with spplot to allow for multiple spplot calls?

thank you,
-david

______________________________________________
R-help@r-project.org mailing list
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.

Reply via email to