| fSheldon | R Documentation |
This function obtains the Sheldon's diversity index introduced by A. L. Sheldon. It is a method for quantifying species biodiversity that can be adapted to the context of onomastics.
fSheldon (x, k, n, location, s)
x |
dataframe of the data values for each species not null (because if you have a sample, there might be species that are not represented).. |
k |
name of a variable which represents absolute frequency for each species. |
n |
name of a variable which represents total number of individuals. |
location |
represents the grouping element. |
s |
vector which represents number of species. |
For a community i, the Sheldon's diversity index is defined by
E_{She} = \frac{2^{H^{\prime}}}{S_i}, where H^{\prime} denotes the Shannon-Wiener index and S_i represents the number of species (richness).
In onomastic context, S_i are all surnames in region (\approx community diversity context) i.
A dataframe containing the following components:
location |
represents the grouping element, for example the communities / regions. |
sheldon |
the value of the Pielou's diversity index. |
Maria Jose Ginzo Villamayor
Sheldon, A. L. (1969). Equitability indices: dependence on the species count. Ecology, 50, 466–467.
fMargalef,
fMenhinick,
fPielou,
fShannon,
fSimpson,
fSimpsonInf,
fGeneralisedMean, fGeometricMean,
fHeip.
library(sqldf)
data(surnamesgal14)
apes2=sqldf('select muni, count(surname) as ni,
sum(number) as population from surnamesgal14
group by muni;')
result = fSheldon (x= surnamesgal14[surnamesgal14$number != 0,],
k="number", n="population", location = "muni",
s = apes2$ni)
result
data(namesmengal16)
names2=sqldf('select muni, count(name) as ni,
sum(number) as population from namesmengal16
group by muni;')
result = fSheldon (x= namesmengal16[namesmengal16$number != 0,],
k="number", n="population", location = "muni",
s = names2$ni)
result
data(nameswomengal16)
names2=sqldf('select muni, count(name) as ni,
sum(number) as population from nameswomengal16
group by muni;')
result = fSheldon (x= nameswomengal16[nameswomengal16$number != 0,],
k="number", n="population", location = "muni",
s = names2$ni)
result
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.