Skip to contents

Load randomized raster object

Usage

unpack_randomized(raster)

Arguments

raster

rd_ras object with randomized raster.

Value

rd_ras

Details

Because of how SpatRaster are saved (need to be packed), this function allows to unpack previously packed raster objects that were saved using pack_randomized. For further details, see wrap.

See also

Examples

if (FALSE) { # \dontrun{
landscape_classified <- classify_habitats(terra::rast(landscape), n = 5, style = "fisher")
landscape_random <- randomize_raster(landscape_classified, n_random = 3)
x <- pack_randomized(raster = landscape_random)
y <- unpack_randomized(raster = y)
} # }