Skip to contents

Writes <prefix>.csv (metrics per projection and rule), <prefix>_categories.csv (criterion-B thresholds met), <prefix>_change.csv (with several projections), <prefix>_patches.csv (area of every patch) and <prefix>_AOO.png.

Usage

write_range_metrics(x, dir, prefix = "range_metrics")

Arguments

x

A range_metrics object.

dir

Output folder.

prefix

File name prefix.

Value

The paths of the written files, invisibly.

References

IUCN (2012) IUCN Red List Categories and Criteria: Version 3.1. Second edition. IUCN, Gland and Cambridge.

Examples

sim <- simulate_enm_data(seed = 1)
tab <- extract_predictions(sim$models[["GLM"]], sim$presence,
                           sim$absence)
rm <- range_metrics(sim$models[["GLM"]], thresholds(tab, rules = "p10"))
#> The raster is in longitude/latitude: EOO, AOO and locations are computed in a Lambert azimuthal equal-area projection centred on it.
write_range_metrics(rm, tempdir())