ageSexAccuracyDasGupta | R Documentation |
Given population counts in 5-year age groups for males and females, follow Das Gupta's steps to calculate a composite index of the quality of the age and sex structure for a given population.
ageSexAccuracyDasGupta(
Males,
Females,
Age,
ageMin = 0,
ageMax = max(Age),
OAG = TRUE
)
Males |
numeric. A vector of demographic counts in 5-year age groups for males. |
Females |
numeric. A vector of demographic counts in 5-year age groups for females. |
Age |
numeric. A vector of ages corresponding to the lower integer bound of the counts. |
ageMin |
integer. The lowest age included in calculations. Default 0. |
ageMax |
integer. The upper age bound used for calculations. Default |
OAG |
logical. Whether or not the top age group is open. Default |
It is assumed that the terminal age group is open, in which case it is ignored.
Set OAG = FALSE
if the top age is indeed a closed interval that you want included in calculations.
If ageMax == max(Age)
and OAG
is TRUE
, then ageMax
gets decremented one age class.
dasgupta1955DemoTools
# data from table for South West Africa (1946) given in reference
Males <- c(2365, 2320, 1859, 1554, 1758, 1534, 1404, 1324,
1118, 872, 795, 745, 743, 574)
Females <- c(2244, 2248, 1773, 1594, 1616, 1510, 1478, 1320,
1085, 858, 768, 726, 533, 282)
Age <- seq(0, 65, by = 5)
ageSexAccuracyDasGupta(Males, Females, Age)
# this method is not on the same scale as the others, so don't directly compare.
ageSexAccuracy(Males, Females, Age, method = "das gupta")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.