prepare_extras
Prepare an extras object
prepare_extras( metrics, landscape_mat, directions, neighbourhood, ordered, base, resolution )
metrics
: A vector with metric abbreviationslandscape_mat
: A matrix objectdirections
: The number of directions in which patches should be connected: 4 (rook's case) or 8 (queen's case).neighbourhood
: The number of directions in which cell adjacencies are considered as neighbours: 4 (rook's case) or 8 (queen's case). The default is 4.ordered
: The type of pairs considered. Either ordered (TRUE) or unordered (FALSE). The default is TRUE.base
: The unit in which entropy is measured. The default is "log2", which compute entropy in "bits". "log" and "log10" can be also used.resolution
: A vector with two numbers (usually calculated using terra::res)A list with zero or more of the following components:
Wrapper around terra::xyFromCell and terra::getValues to get raster_to_points function including NA values
landscape <- terra::rast(landscapemetrics::landscape) landscape_mat <- terra::as.matrix(landscape, wide = TRUE) prepare_extras("lsm_l_ent", landscape_mat, neighbourhood = 4, base = "log2") ## Not run: metrics = list_lsm()$function_name landscape <- terra::rast(landscapemetrics::landscape) landscape_mat <- terra::as.matrix(landscape, wide = TRUE) prepare_extras(metrics, landscape_mat, directions = 8, neighbourhood = 4, ordered = FALSE, base = "log2", resolution = terra::res(landscape)) ## End(Not run)
get_points
, get_class_patches
, get_area_patches
, get_complexity
, get_enn_patch
Useful links