div_part: Diversity partition

View source: R/div_part.R

div_partR Documentation

Diversity partition

Description

Calculate \gamma, \beta and \alpha diversities of a metacommunity.

Usage

div_part(
  abundances,
  q = 1,
  estimator = c("UnveilJ", "ChaoJost", "ChaoShen", "GenCov", "Grassberger", "Holste",
    "Marcon", "UnveilC", "UnveiliC", "ZhangGrabchak"),
  level = NULL,
  probability_estimator = c("Chao2015", "Chao2013", "ChaoShen", "naive"),
  unveiling = c("geometric", "uniform", "none"),
  richness_estimator = c("jackknife", "iChao1", "Chao1", "naive"),
  jack_alpha = 0.05,
  jack_max = 10,
  coverage_estimator = c("ZhangHuang", "Chao", "Turing", "Good"),
  q_threshold = 10,
  check_arguments = TRUE
)

Arguments

abundances

an object of class abundances.

q

a number: the order of diversity.

estimator

An estimator of diversity.

level

the level of interpolation or extrapolation. It may be a sample size (an integer) or a sample coverage (a number between 0 and 1). If not NULL, the asymptotic estimator is ignored.

probability_estimator

a string containing one of the possible estimators of the probability distribution (see probabilities). Used only for extrapolation.

unveiling

a string containing one of the possible unveiling methods to estimate the probabilities of the unobserved species (see probabilities). Used only for extrapolation.

richness_estimator

an estimator of richness to evaluate the total number of species, see div_richness. used for interpolation and extrapolation.

jack_alpha

the risk level, 5% by default, used to optimize the jackknife order.

jack_max

the highest jackknife order allowed. Default is 10.

coverage_estimator

an estimator of sample coverage used by coverage.

q_threshold

the value of q above which diversity is computed directly with the naive estimator (\sum{p_s^q}^{\frac{1}{(1-q)}}, without computing entropy. When q is great, the exponential of entropy goes to 0^{\frac{1}{(1-q)}}, causing rounding errors while the naive estimator of diversity is less and less biased.

check_arguments

if TRUE, the function arguments are verified. Should be set to FALSE to save time when the arguments have been checked elsewhere.

Details

The function computes \gamma diversity after building a metacommunity from local communities according to their weight \insertCiteMarcon2014adivent. \alpha entropy is the weighted mean local entropy, converted into Hill numbers to obtain \alpha diversity. \beta diversity is obtained as the ratio of \gamma to \alpha.

Value

A tibble with diversity values at each scale.

References

\insertAllCited

Examples

div_part(paracou_6_abd)


divent documentation built on April 3, 2025, 7:40 p.m.