A single ratio is defined as males per 100 females. Taking the first difference of the ratios over age would give 0s if the ratio were constant. The average absolute difference over age defines the index. This comes from the PAS spreadsheet called AGESEX.
sexRatioScore(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 |
The value of the index.
Age groups must be of equal intervals. Five year age groups are assumed.
It is also assumed that the final age group is open, unless ageMax < max(Age)
.
United Nations (1952). “Accuracy tests for census age distributions tabulated in five-year and ten-year groups.” Population Bulletin, 59--79. United States Census Bureau (2017). “Population Analysis System (PAS) Software.” https://www.census.gov/data/software/pas.html, https://www.census.gov/data/software/pas.html.
Males <- c(4677000,4135000,3825000,3647000,3247000,2802000,2409000,2212000, 1786000,1505000,1390000,984000,745000,537000,346000,335000) Females <- c(4544000,4042000,3735000,3647000,3309000,2793000,2353000,2112000, 1691000,1409000,1241000,887000,697000,525000,348000,366000) Age <- seq(0, 75, by = 5) sexRatioScore(Males, Females, Age) # 2.2, matches PAS#> [1] 2.248535