Skip to contents

Prepare for fitting SDMs by reclassifying a landscape rasters according to the classifications used by a specific set of species distribution models (SDM).

Usage

reclassify_landcover(landscape, SDM)

Arguments

landscape

SpatRaster created by terra::rast()

SDM

The name of intended species distribution model: "riparian", "waterbird_fall", "waterbird_win", or "tima"

Value

SpatRaster with separate layers for each land cover class included as a predictor in the selected SDM representing the presence (1) and absence (0)

Details

Calls on internal datsets to crosswalk land cover classes encoded in the provided landscape predictors expected by the selected set of SDMs. This function is called by python_focal_prep() on a set of landscape rasters generated by segregating an input landscape by class. It is not intended to be called directly.

Warnings are given if land cover classes are present in the landscape but are excluded from model consideration, which may be a problem particularly if they represent a large portion of the landscape. In this case, review the corresponding internal dataset (predictors_riparian(), predictors_waterbird_fall(), predictors_waterbird_win(), or predictors_tima()) to understand whether the model is expecting more specific land cover classes or subclasses; the provided landscape may need to be adjusted first.

Warnings are also given if land cover classes are expected by the model but are absent from the landscape. These land covers will be assumed absent from the provided landscape and filled in with all 0 values, but these missing land covers should be carefully reviewed to ensure they aren't excluded from the landscape and model predictions unintentionally. If needed, the resulting layers can be replaced manually before proceeding with python_focal_run().

See also

key(), predictors_riparian(), predictors_waterbird_fall(), predictors_waterbird_win(), or predictors_tima() for more details on the list of recognized landcover classes and subclasses and how they crosswalk to land cover predictors for each set of SDMs

Examples