Calculates landscape metrics for categorical landscape patterns in a tidy workflow. 'landscapemetrics' reimplements the most common metrics from 'FRAGSTATS' (< https://www.umass.edu/landeco/research/fragstats/fragstats.html>) and new ones from the current literature on landscape metrics. This package supports 'raster' spatial objects and takes RasterLayer, RasterStacks, RasterBricks or lists of RasterLayer from the 'raster' package as input arguments. It further provides utility functions to visualize patches, select metrics and building blocks to develop new metrics.
lsm_c_ai()
if only one class and NA values were presentshow_correlation()
that first col was lostsample_lsm()
and extract_lsm()
to forward arguments to
calculate_lsm()
sample_lsm()
is now comparable between squares and circleswindow_lsm()
that some arguments were not passed on (resolution and points)extract_lsm()
and window_lsm()
that allowed metric subset was wrongshow_correlation()
list_lsm()
allows to return all BUT the selected metricssample_lsm()
can now use SpatialPolygons to sample metricssample_lsm()
can now handle SpatialLines to sample metricssample_lsm()
automatically detects provided data typeextract_lsm()
can now handle SpatialLines to extract metricslsm_l_ent()
and thus lsm_l_condent()
and lsm_l_mutinf()
.calculate_lsm()
/extract_lsm()
/sample_lsm()
/spatialize_lsm()
/window_lsm()
can print progresscat()
with message()
calculate_lsm()
returns an error message if selected metrics do not existconstruct_buffer()
can now return a matrix with coords instead of polygonscalculate_lsm()
checks the input data before calculating metricsget_lsm()
is now called spatialize_lsm()
moving_window()
to calculate metrics within a moving windowget_lsm()
to raster in which each cell has patch metric valuecheck_landscape()
if NA values were presentpad_raster()
that pad_raster_cells > 1 did not workcalculate_lsm()
calculating class area where resolution was lostdplyr
check_landscape()
check_landscape()
pad_raster()
is now typestable and always returns a listpad_raster()
can now return also a RasterLayer (and not just a matrix as)sample_lsm()
that occured when metrics where selected using what
argumentlsm_p_core()
if only one patch is presentlsm_p_circle()
if only one cell is present in classlsm_p_hyrate()
if only one cell is present in classget_adjacencies()
that checks if neighbourhood
was specified correctly did not work properlysample_lsm()
now returns a tibble including an extra column if return_raster = TRUE
(and not a nested tibble as before)list_lsm()
, calculate_lsm()
and ``sample_lsm()`return_plots
to return_raster
in sample_lsm()
check_landscape
to make sure your landscapes are feasible for landscapemetricsraster_to_points()
to get also NA cells (not possible with raster::rasterToPoints
)get_boundaries()
to get only boundary cellsget_unique_values()
that shows all uniques labels in a classlist_lsm()
function to print available metricsshow_lsm()
function to vizualize patch level metricslsm_l_rpr
: Typo in internal function, used landscapemetrics::landscape instead of user inputshow_()
* functions that na.value color is identicalget_
-functions can now take matrix as input and also return a matrixcalculate_lsm()
now uses list_lsm()
. This allows more options to specify metrics to calculatelsm_abbreviations_names
show_()
-functions don't throw warningsshow_()
functionsextract_lsm()
now uses list_lsm()
. This allows more options to specify metrics to calculatercpp_get_coocurrence_matrix()
can now handle large rasters and is fasterlsm_p_circle()
and get_circumscribingcircle()
now consideres different x- & y-resolutionswhat
arguments of all show_()
-functions now are named class
for consistency (so all what
arguments deal with metrics)what
arguments of get_patches()
is now named class
for consistency (so all what
arguments deal with metrics)calculate_metrics
is now calculate_lsm
show_cores
, a function to plot the core area of patchesshow_patches
now also shows labelled class facets (option what
)sample_lsm
, a function to sample metrics around buffered pointsextract_lsm
, a function to extract landscape metrics for spatial coordinatespurrr
package and replaced them by lapply
calculate_lsm
has the option progress
consider_boundary
is available for all core metricsedge_depth
can be specified for all core metrics