Re: [R-sig-Geo] how to plot different rows of a SpatialPolygonsDataFrame in trellis panels

2018-06-01 Thread Roger Bivand
ect: Re: how to plot different rows of a SpatialPolygonsDataFrame in trellis panels On Thu, May 24, 2018 at 6:00 AM, wrote: Message: 1 Date: Wed, 23 May 2018 18:39:07 + From: "Waichler, Scott R" To: "r-sig-geo@r-project.org" Subject: [R-sig-Geo] how to plot different ro

Re: [R-sig-Geo] how to plot different rows of a SpatialPolygonsDataFrame in trellis panels

2018-05-31 Thread Edzer Pebesma
Thu, May 24, 2018 at 6:00 AM, wrote: >> >> Message: 1 >> Date: Wed, 23 May 2018 18:39:07 +0000 >> From: "Waichler, Scott R" >> To: "r-sig-geo@r-project.org" >> Subject: [R-sig-Geo] how to plot different rows of a >>         SpatialPolygonsDataF

Re: [R-sig-Geo] how to plot different rows of a SpatialPolygonsDataFrame in trellis panels

2018-05-31 Thread Waichler, Scott R
s panels > > On Thu, May 24, 2018 at 6:00 AM, wrote: > > Message: 1 > Date: Wed, 23 May 2018 18:39:07 + > From: "Waichler, Scott R" > To: "r-sig-geo@r-project.org" > Subject: [R-sig-Geo] how to plot different rows of a >         SpatialPolygonsDat

Re: [R-sig-Geo] how to plot different rows of a SpatialPolygonsDataFrame in trellis panels

2018-05-24 Thread Kent Johnson
On Thu, May 24, 2018 at 6:00 AM, wrote: > > Message: 1 > Date: Wed, 23 May 2018 18:39:07 + > From: "Waichler, Scott R" > To: "r-sig-geo@r-project.org" > Subject: [R-sig-Geo] how to plot different rows of a > SpatialPolygonsDataFrame

Re: [R-sig-Geo] how to plot different rows of a SpatialPolygonsDataFrame in trellis panels

2018-05-23 Thread Bede-Fazekas Ákos
Dear Scott, use spplot(tmp, zcol="z") instead of spplot(tmp, zcol=z) to display the column "z". Use spplot(tmp[tmp$id == 1, ], zcol = "z") to display only those grids that has id 1. And to display two panels: tmp$z1 <- tmp$z2 <- tmp$z tmp$z1[tmp$id == 1] <-  NA tmp$z2[tmp$id == 2] <-  NA spplot

Re: [R-sig-Geo] how to plot different rows of a SpatialPolygonsDataFrame in trellis panels

2018-05-23 Thread Waichler, Scott R
Roger, > Without having tried your code, how similar is this to these packages: > > https://cran.r-project.org/package=micromap > https://cran.r-project.org/package=micromapST Thanks for responding. I looked at the micromap vignettes but it seems their focus is being able to provide small maps

Re: [R-sig-Geo] how to plot different rows of a SpatialPolygonsDataFrame in trellis panels

2018-05-23 Thread Roger Bivand
Scott, Without having tried your code, how similar is this to these packages: https://cran.r-project.org/package=micromap https://cran.r-project.org/package=micromapST and their JSS papers: https://www.jstatsoft.org/index.php/jss/article/view/v063i02 https://www.jstatsoft.org/index.php/jss/art

[R-sig-Geo] how to plot different rows of a SpatialPolygonsDataFrame in trellis panels

2018-05-23 Thread Waichler, Scott R
Hello, I have a SpatialPolygonsDataFrame. I would like to do a trellis plot on one of the attributes, so that in the panel for a given attribute value, only those polygons with that value are plotted. So, each panel has different polygons plotted in it. I can't figure out how to do this. In