Compute Functional Divergence (FDiv)Source:
Compute Functional Divergence (FDiv)
The matrix dataset for which you want to compute the index
Site-species matrix with sites as rows and species as columns if not provided, the function considers all species with equal abundance in a single site. This can be either a
data.frame, or a
a data.frame with two columns:
sitethe names of the sites as the row names of the input
FDivthe values of functional divergence at each site.
NB: when a site contains no species FDiv is equal to 0.
By default, when loading fundiversity, the functions to
compute convex hulls are
memoised through the
package if it is installed. To deactivate this behavior you can set the
FALSE by running the following line:
options(fundiversity.memoise = FALSE). If you use it interactively it will
only affect your current session. Add it to your script(s) or
file to avoid toggling it each time.
The computation of this function can be parallelized thanks to
future::plan(). To get more information on how to parallelize your
computation please refer to the parallelization vignette with:
vignette("parallel", package = "fundiversity")
Villéger S., Mason N. W. H., Mouillot D. (2008), New multidimensional functional diversity indices for a multifaceted framework in functional ecology, Ecology 89(8), doi: 10.1890/07-1206.1
data(traits_birds) fd_fdiv(traits_birds) #> site FDiv #> 1 s1 0.7282172