reweight_age_pyr | R Documentation |
This function re-weights a given age pyramid (i.e., a vector with one element per year in an age range that specifies what proportion of the population should be that age) so that the desired fraction of the population falls below a specified age boundary.
reweight_age_pyr(age.pyramid, young.prop, age.break)
age.pyramid |
A vector of proportions. |
young.prop |
The weight that should be applied to the portion of
|
age.break |
The index at which the upper group should begin. |
unif.age.pyr <- rep(1/100, 100)
reweighted.age.pyr <- reweight_age_pyr(unif.age.pyr, 0.995, 65)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.