Description Usage Arguments Details Value References Examples
Calculate estimates of the Shannon-Wiener index after pooling over several samples, grouped by a factor variable.
1 | estShannonf(X, f)
|
X |
a data.frame of dimension n times p with integer entries, where n is the number of samples and p is the number of species |
f |
a factor variable of length n, grouping the observations in X |
The function splits X according to the levels of the grouping variable f, builds the sum over each column and calculates the Shannon index ove the resulting counts.
A list, containing the elements:
estimae |
a named numeric vector, the groupwise Shannon indices with bias correction according to Fritsch and Hsu (1999) |
estraw |
a named numeric vector, the groupwise Shannon indices, without bias correction |
varest |
a named numeric vector, the groupwise variance estimates of the Shannon indices |
table |
a matrix, giving the summarized counts of the groups in the rows |
Fritsch, KS, and Hsu, JC (1999): Multiple Comparison of Entropies with Application to Dinosaur Biodiversity. Biometrics 55, 1300-1305.
1 2 3 4 5 6 7 8 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.