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
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
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
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
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
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
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
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