The R package ecopart
("Ecological COmmunity PARTitioning" or "Extinction and COlonization PARTitioning") allows one to partition the temporal changes in beta diversity into multiple components. The components represent biotic homogenization and differentiation (i.e., decreases and increases in beta diversity) that result from local extinctions and colonizations of species or the losses and gains in species abundances. The pacakge consists of two functions: ecopart.pair()
and ecopart.multi()
.
#library(remotes)
remotes::install_github("communityecologist/ecopart")
library(ecopart)
ecopart.pair(d1, d2, index = "sorensen", components="four")
d1
: A matrix or dataframe at time 1. Rows are a pair of sites (sites 1 and 2), columns are species, and elements are presence-absence (01) or abundances of species.d2
: A matrix or dataframe at time 2. Note that d1 and d2 must have exactly the same sites and species in the same order.index
: Type of dissimilarity measure. Options are "jaccard", "sorensen", "ruzicka", and "bray-curtis".components
: Types of components into which the total change in beta diversity is partitioned. Options are "two", "four", "six", and "sp".ecopart.multi(d1, d2, index = "whittaker", components="four")
d1
: A matrix or dataframe at time 1. Rows are sites, columns are species, and elements are presence-absence (01) or abundances of species.d2
: A matrix or dataframe at time 2. Note that d1 and d2 must have exactly the same sites and species in the same order.index
: Type of dissimilarity measure. Options are "whittaker" and "baselga".components
: Types of components into which the total change in beta diversity is partitioned. Options are "two", "four", and "sp".Run ?ecopart.pair()
and ?ecopart.multi()
for detail.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.