add | R Documentation |
Add (in place) a SpatRaster to another SpatRaster. Comparable with c
, but without copying the object.
## S4 replacement method for signature 'SpatRaster,SpatRaster'
add(x)<-value
## S4 replacement method for signature 'SpatRasterDataset,SpatRaster'
add(x)<-value
## S4 replacement method for signature 'SpatRasterCollection,SpatRaster'
add(x)<-value
x |
SpatRaster, SpatRasterDataset or SpatRasterCollection |
value |
SpatRaster |
SpatRaster
c
r <- rast(nrows=5, ncols=9, vals=1:45)
x <- c(r, r*2)
add(x) <- r*3
x
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.