In the entropart package, individuals of different "species" are counted in several "communities" which are agregated to define a "metacommunity".
This is a naming convention, which may correspond to plots in a forest inventory or any data organized the same way.
Alpha and beta entropies of communities are summed according to Weights
and the probability to find a species in the metacommunity is the weighted average of probabilities in communities.
The simplest way to import data is to organize it into two text files. The first file should contain abundance data: the first column named Species
for species names, and a column for each community.
Species |
NameOfCommunity1 |
NameOfCommunity2 |
NameOfSpecies1 |
1 |
5 |
NameOfSpecies2 |
4 |
2 |
The second file should contain the community weights and be organized as follows:
Communities |
Weights |
NameOfCommunity1 |
3 |
Files can be read and data imported by code such as:
Abundances <- read.csv(file="Abundances.csv", row.names = 1)
Weights <- read.csv(file="Weights.csv")
MC <- MetaCommunity(Abundances, Weights)
The number of individuals of the meta-community $N
is not explicitly specified. It is calculated as the number of individuals of the lower-weighted community divided by its weight. For example, if the community with the smallest weight (5%) contains 100 individuals, the total number of individuals is set to 2000. The number of individuals per species of the meta-community $Ns
is the product of $N
and $Ps
. In the special case where weights are proportional to the number of individuals of communities, the resulting number of individuals of the meta-community is simply the sum of the number of individuals of communities. In other cases, the numbers of individuals of the meta-community may not be integers. This does not appear to be a problem.