AOO.decline(
XY,
hab.map,
cell_size_AOO = 2,
nbe.rep.rast.AOO = 0,
parallel = FALSE,
NbeCores = 2,
show_progress = TRUE,
proj_type = "cea",
hab.class = NULL,
hab.map.type = NULL,
all_individual_layers = FALSE
)data.frame see Details.
SpatRaster or sf polygons containing the habitat spatial information
numeric, by default is 2. Value indicating the grid size in kilometres used for estimating Area of Occupancy.
numeric, by default is 0. Indicate the number of raster with random starting position used for estimating the AOO. If 0 but some translation of the raster are still done.
a logical. Whether running should be performed in parallel. FALSE by default.
an integer. Register the number of cores for parallel execution. Two by default.
logical. Whether progress informations should displayed. TRUE by default
string or numeric
classes of values in hab.map to be considered as suitable
logical, vector of same length of hab.map,
TRUE means the habitat of hab.map is suitable
FALSE means the habitat of hab.map is unsuitable
logical
TRUE compute AOO decline for each individual hab.map
FALSE (the default) compute AOO decline for all layers together
AOOs a dataframe of AOO estimates for each taxa and for each layer/spatial polygons if all_individual_layers is TRUE
AOO_decline a dataframe of AOO.decline in percentages
categories based on the sub-criteria of IUCN criterion A
Input as a data.frame should have the following structure:
It is mandatory to respect field positions, but field names do not matter
| latitude | longitude | species |
| numeric | numeric | character |
The argument nbe.rep.rast.AOO should ideally be higher than 20 for increasing
the chance to get the minimal number of occupied cell. Increasing nbe.rep.rast.AOO however
also increase the computing time. So this is a trade-off that depends on the importance to
get the minimal AOO and the size of the dataset.
m <- matrix(1:25, nrow=5, ncol=5)
rm <- terra::rast(m)
terra::values(rm) <- sample(c("forest", "cities", "roads"), 25, replace = TRUE)
cls <- data.frame(id=1:3, cover=c("forest", "cities", "roads"))
levels(rm) <- cls
terra::crs(rm) <- "epsg:4326"
test_data <- dummy_dist(n = 5, xmin = 0, xmax = 5, ymin = 0, ymax = 5)
res <- AOO.decline(
XY = test_data,
hab.map = rm,
hab.class = c("forest"),
all_individual_layers = TRUE
)
#> hab.map.type not provided, all hab.map provided are considered as suitable
#> Total Area of occupancy
#>
|
| | 0%
|
|============== | 20%
|
|============================ | 40%
|
|========================================== | 60%
|
|======================================================== | 80%
|
|======================================================================| 100%
#> Area of occupancy minus threatened areas for each layers individually
#> [1] "hab.map.1"
#>
|
| | 0%
|
|============== | 20%
|
|============================ | 40%
|
|========================================== | 60%
|
|======================================================== | 80%
|
|======================================================================| 100%
#>
|
| | 0%
|
|============== | 20%
|
|============================ | 40%
|
|========================================== | 60%
|
|======================================================== | 80%
|
|======================================================================| 100%
#> Warning: The following subcriteria were not used in the assessment: A1, A3, A4
res <- AOO.decline(
XY = test_data,
hab.map = rm,
hab.class = c("cities", "roads"),
all_individual_layers = TRUE,
hab.map.type = FALSE ### this means the provided hab.map is unsuitable
)
#> Total Area of occupancy
#>
|
| | 0%
|
|============== | 20%
|
|============================ | 40%
|
|========================================== | 60%
|
|======================================================== | 80%
|
|======================================================================| 100%
#> Area of occupancy minus threatened areas for each layers individually
#> [1] "hab.map.1"
#>
|
| | 0%
|
|============== | 20%
|
|============================ | 40%
|
|========================================== | 60%
|
|======================================================== | 80%
|
|======================================================================| 100%
#>
|
| | 0%
|
|============== | 20%
|
|============================ | 40%
|
|========================================== | 60%
|
|======================================================== | 80%
|
|======================================================================| 100%
#> Warning: The following subcriteria were not used in the assessment: A1, A3, A4