| class_layers | R Documentation |
Splits the classified raster of a "landform" object into one
presence/absence layer per class, named after the classes. This replaces the
list of per-class rasters returned by landform <= 0.2.
class_layers(x, absent = 0)
x |
An object of class |
absent |
Value given to cells not belonging to the class: |
A multi-layer SpatRaster with one layer for each class
present in the classification (1 = cell belongs to the class); cells left
unclassified are NA in every layer.
dem <- malta_dtm()
sp <- landform(dem, scale = 9, plot = FALSE)
layers <- class_layers(sp)
names(layers)
terra::plot(layers[["Ridge"]], main = "Ridge")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.