AOO.decline: Area of occupancy decline

View source: R/AOO.decline.R

AOO.declineR Documentation

Area of occupancy decline

Description

[Experimental] Estimate areas of occupancy (AOO) decline for multiple taxa in square kilometres and percentage

Usage

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
)

Arguments

XY

data.frame see Details.

hab.map

SpatRaster or sf polygons containing the habitat spatial information

cell_size_AOO

numeric, by default is 2. Value indicating the grid size in kilometres used for estimating Area of Occupancy.

nbe.rep.rast.AOO

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.

parallel

a logical. Whether running should be performed in parallel. FALSE by default.

NbeCores

an integer. Register the number of cores for parallel execution. Two by default.

show_progress

logical. Whether progress informations should displayed. TRUE by default

proj_type

string or numeric

hab.class

classes of values in hab.map to be considered as suitable

hab.map.type

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

all_individual_layers

logical

  • TRUE compute AOO decline for each individual hab.map

  • FALSE (the default) compute AOO decline for all layers together

Details

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.

Value

  1. AOOs a dataframe of AOO estimates for each taxa and for each layer/spatial polygons if all_individual_layers is TRUE

  2. AOO_decline a dataframe of AOO.decline in percentages

  3. categories based on the sub-criteria of IUCN criterion A

Author(s)

Gilles Dauby, gildauby@gmail.com

Examples


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
)


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
)



gdauby/ConR documentation built on Jan. 30, 2024, 11:10 p.m.