I want to plot my kriging-results which are stored in a SpatialPixelsDataFrame object. Using spplot, it automatically creates a plot including var1.pred, var1.var and var1.stdev.
This is nice, but I want the spplot function to only plot var1.pred, which is why I want to delete var1.var and var1.stdev (they are stored as attributes in the slot @data).
I don't know how to do this - can anybody help? Thanks in advance!
Let's say my object is called "aa", then here is the information about it:
str(aa)
Formal class 'SpatialPixelsDataFrame' [package "sp"] with 7 slots
..@ data :'data.frame': 4986 obs. of 3 variables:
.. ..$ var1.pred : num [1:4986] 5.95 5.96 5.96 5.94 5.95 ...
.. ..$ var1.var : num [1:4986] 0.000445 0.0005 0.00072 0.008354 0.000917 ...
.. ..$ var1.stdev: num [1:4986] 0.0211 0.0224 0.0268 0.0914 0.0303 ...
..@ coords.nrs : int [1:2] 1 2
..@ grid :Formal class 'GridTopology' [package "sp"] with 3 slots
.. .. ..@ cellcentre.offset: Named num [1:2] 0.139 0.408
.. .. .. ..- attr(*, "names")= chr [1:2] "x1" "x2"
.. .. ..@ cellsize : Named num [1:2] 0.174 0.174
.. .. .. ..- attr(*, "names")= chr [1:2] "x1" "x2"
.. .. ..@ cells.dim : Named int [1:2] 56 154
.. .. .. ..- attr(*, "names")= chr [1:2] "x1" "x2"
..@ grid.index : int [1:4986] 8604 8548 8492 8435 8436 8379 8380 8323 8324 8325 ...
..@ coords : num [1:4986, 1:2] 6.22 6.22 6.22 6.05 6.22 ...
.. ..- attr(*, "dimnames")=List of 2
.. .. ..$ : NULL
.. .. ..$ : chr [1:2] "x1" "x2"
..@ bbox : num [1:2, 1:2] 0.139 0.408 9.697 26.994
.. ..- attr(*, "dimnames")=List of 2
.. .. ..$ : chr [1:2] "x1" "x2"
.. .. ..$ : chr [1:2] "min" "max"
..@ proj4string:Formal class 'CRS' [package "sp"] with 1 slots
.. .. ..@ projargs: chr NA