Calculates Rao's quadratic entropy of a community described by a probability vector and a phylogenetic / functional tree.
Rao(NorP, Tree, ...) bcRao(Ns, Tree, Correction="Lande", CheckArguments = TRUE) # S3 method for ProbaVector Rao(NorP, Tree, ..., CheckArguments = TRUE, Ps = NULL) # S3 method for AbdVector Rao(NorP, Tree, Correction = "Lande", ..., CheckArguments = TRUE, Ns = NULL) # S3 method for integer Rao(NorP, Tree, Correction = "Lande", ..., CheckArguments = TRUE, Ns = NULL) # S3 method for numeric Rao(NorP, Tree, Correction = "Lande", ..., CheckArguments = TRUE, Ps = NULL, Ns = NULL)
A probability vector, summing to 1.
A numeric vector containing species abundances.
A string containing one of the possible corrections accepted by
"Lande", the default value (equivalent to
Additional arguments. Unused.
TRUE, the function arguments are verified. Should be set to
FALSE to save time when the arguments have been checked elsewhere.
Bias correction requires the number of individuals. Use
bcRao and choose the
The unbiased estimator of Rao's entropy is identical to that of Simpson's entropy because Rao's entropy is a linear sum of Simson entropies, all of them calculated from the same number of individuals (Marcon and Herault, 2014). It equals the plug-in etimator multiplied by n/(n-1) where n is the total number of individuals.
The functions are designed to be used as simply as possible.
Tsallis is a generic method. If its first argument is an abundance vector, an integer vector or a numeric vector which does not sum to 1, the bias corrected function
bcTsallis is called. Explicit calls to
bcTsallis (with bias correction) or to
Tsallis.ProbaVector (without correction) are possible to avoid ambiguity. The
.numeric methods accept
Ns arguments instead of
NorP for backward compatibility.
A named number equal to the calculated entropy. The name is that of the bias correction used.
Marcon, E., Herault, B. (2015). Decomposing Phylodiversity. Methods in Ecology and Evolution 6(3): 333-339.
Rao, C. R. (1982). Diversity and dissimilarity coefficients: a unified approach. Theoretical Population Biology 21: 24-43.
# Load Paracou data (number of trees per species in two 1-ha plot of a tropical forest) data(Paracou618) # Ns is the total number of trees per species Ns <- as.AbdVector(Paracou618.MC$Ns) # Species probabilities Ps <- as.ProbaVector(Paracou618.MC$Ns) # Calculate Rao's quadratic entropy of the plot Rao(Ps, Paracou618.Taxonomy) #> None #> 2.878133