| Title: | Harmonized Orphanhood Mortality Estimation |
|---|---|
| Description: | Implements indirect demographic methods for estimating adult mortality from orphanhood data. The package includes the standard Brass (1973) method, the regression-based approach developed by Timaeus (1991), and the adjustments proposed by Luy (2012) for low-mortality populations <doi:10.1007/s13524-012-0101-7>. A relational model is used to harmonize estimates into comparable adult mortality indicators. The package also provides diagnostic tools to assess the sensitivity of results to assumptions about the mean age of childbearing and the choice of model life table family. |
| Authors: | Tamara Vaz [aut, cre] |
| Maintainer: | Tamara Vaz <[email protected]> |
| License: | MIT + file LICENSE |
| Version: | 0.1.0 |
| Built: | 2026-06-03 09:43:51 UTC |
| Source: | https://github.com/tamaravaz/home |
Opens the interactive dashboard for indirect adult mortality estimation
using the orphanhood-based methods implemented in the HOME package.
The application provides a graphical interface to om_estimate_index,
om_plot_linearity, om_sensitivity, and
om_sensitivity_family.
app_HOME()app_HOME()
The Shiny application is located in inst/shiny/home_app/ and is
launched via shiny::runApp(). An active R session with the
shiny, bslib, plotly, DT, readxl, and
writexl packages is required; these are listed under Suggests
in the package DESCRIPTION file.
This function is called for its side effect of launching a Shiny
application. It does not return a meaningful value; the return value of
shiny::runApp() is returned invisibly.
om_estimate_index for the underlying estimation
function.
## Not run: app_HOME() ## End(Not run)## Not run: app_HOME() ## End(Not run)
Produces a three-panel diagnostic display combining the internal consistency check with sensitivity analyses for mean age of childbearing and model life table family. Requires the gridExtra package.
om_dashboard( object, index = "30q30", family_type = "UN", range_m = seq(-1.5, 1.5, 0.5) )om_dashboard( object, index = "30q30", family_type = "UN", range_m = seq(-1.5, 1.5, 0.5) )
object |
An object of class |
index |
Character. Mortality index to display in sensitivity panels.
One of |
family_type |
Character. Life table family system for the family
sensitivity panel. One of |
range_m |
Numeric vector. Offsets applied to the mean age of
childbearing. Default: |
If gridExtra is available, arranges and displays the three
plots and returns the gtable object invisibly. Otherwise returns a
named list with elements Linearity, Sensitivity_M, and
Sensitivity_Family.
om_plot_linearity, om_sensitivity,
om_sensitivity_family
## Not run: result <- om_estimate_index( method = "luy", sex_parent = "Female", age_respondent = seq(20, 60, by = 5), p_surv = c(0.987, 0.967, 0.934, 0.908, 0.882, 0.835, 0.769, 0.669, 0.565), mean_age_parent = rep(27, 9), surv_date = 1998.5 ) om_dashboard(result, index = "30q30", family_type = "UN") ## End(Not run)## Not run: result <- om_estimate_index( method = "luy", sex_parent = "Female", age_respondent = seq(20, 60, by = 5), p_surv = c(0.987, 0.967, 0.934, 0.908, 0.882, 0.835, 0.769, 0.669, 0.565), mean_age_parent = rep(27, 9), surv_date = 1998.5 ) om_dashboard(result, index = "30q30", family_type = "UN") ## End(Not run)
Estimates conditional survivorship probabilities using orphanhood methods and harmonizes them into common adult mortality indices using a one-parameter relational logit model.
om_estimate_index( method = c("luy", "timaeus", "brass"), sex_parent = c("Female", "Male"), age_respondent, p_surv, mean_age_parent, surv_date, num_respondents = NULL, model_family = "General" )om_estimate_index( method = c("luy", "timaeus", "brass"), sex_parent = c("Female", "Male"), age_respondent, p_surv, mean_age_parent, surv_date, num_respondents = NULL, model_family = "General" )
method |
Character. Estimation method. One of |
sex_parent |
Character. Sex of the parent. One of |
age_respondent |
Numeric vector. Lower bound of respondent age groups
(e.g., |
p_surv |
Numeric vector. Proportion of respondents reporting the parent alive, one value per age group. |
mean_age_parent |
Numeric scalar or vector. Mean age of parents at
respondent's birth ( |
surv_date |
Numeric. Survey reference date as a decimal year
(e.g., |
num_respondents |
Numeric vector. Optional. Number of respondents per age group. Reserved for future use; currently has no effect on estimates. |
model_family |
Character. Model life table family used as the relational
logit standard. UN families: |
Three orphanhood-based estimation methods are supported. Regardless of the method selected, estimates are harmonized into three comparable mortality indices:
30q30: Probability of dying between ages 30 and 60.
45q15: Probability of dying between ages 15 and 60.
e30: Life expectancy at age 30.
For the Brass method, adjacent orphanhood proportions are paired across
successive age groups. The first observation yields NA by
construction because no preceding adjacent proportion exists.
An object of class OrphanhoodEstimate, a named list with:
estimatesData frame of estimated adult mortality indices by respondent age group. Columns:
MethodCitation label of the estimation method used.
RefYearEstimated reference year of the mortality estimate, expressed as a decimal year.
AgeLower bound of the respondent age group () used to
derive the orphanhood estimate.
bInitial exact age of the conditional survivorship interval.
Equals 30 for Luy (2012); 25 for Timaeus (1992) females,
35 for males; 25 for Brass (1973) females, 32.5 or 37.5
for males depending on .
n_bTerminal exact age of the survivorship interval
(). For Luy (2012) this equals
.
l(b)Estimated survivorship at exact age , derived from
the relational logit model.
l(n_b)Estimated survivorship at exact age , derived from
the relational logit model.
lx_ratioConditional survivorship probability ,
i.e.\ the probability of surviving from exact age
to exact age . This is the key observable quantity
derived from the orphanhood method and used to estimate
Alpha.
AlphaRelational logit level parameter estimated by
solving against the
standard life table. Higher values indicate lower mortality.
30q30Probability of dying between exact ages 30 and 60.
45q15Probability of dying between exact ages 15 and 60.
e30Life expectancy at exact age 30.
metaNamed list of metadata: sex of the parent, model life table family,
family system type ("UN" or "CD"), method identifier,
and primary index name.
inputsNamed list of the original input arguments, retained for
reproducibility and use by om_sensitivity and
om_sensitivity_family.
om_sensitivity, om_sensitivity_family,
om_plot_linearity
## Not run: result <- om_estimate_index( method = "brass", sex_parent = "Female", age_respondent = c(20, 25, 30, 35, 40, 45), p_surv = c(0.906, 0.840, 0.747, 0.631, 0.518, 0.400), mean_age_parent = 28.8, surv_date = 1975.64, model_family = "General" ) print(result) ## End(Not run)## Not run: result <- om_estimate_index( method = "brass", sex_parent = "Female", age_respondent = c(20, 25, 30, 35, 40, 45), p_surv = c(0.906, 0.840, 0.747, 0.631, 0.518, 0.400), mean_age_parent = 28.8, surv_date = 1975.64, model_family = "General" ) print(result) ## End(Not run)
Displays the estimated Brass logit parameter across respondent
age groups. A roughly constant indicates internal consistency
of the orphanhood-based estimates; a systematic trend suggests age-reporting
errors, adoption effects, or structural changes in mortality.
om_plot_linearity(object)om_plot_linearity(object)
object |
An object of class |
A ggplot object with respondent age group (Age) on
the x-axis and the relational logit level parameter
(Alpha) on the y-axis. A dashed horizontal line marks the median
across age groups.
om_estimate_index, om_dashboard
## Not run: result <- om_estimate_index( method = "luy", sex_parent = "Female", age_respondent = seq(20, 60, by = 5), p_surv = c(0.987, 0.967, 0.934, 0.908, 0.882, 0.835, 0.769, 0.669, 0.565), mean_age_parent = rep(27, 9), surv_date = 1998.5 ) om_plot_linearity(result) ## End(Not run)## Not run: result <- om_estimate_index( method = "luy", sex_parent = "Female", age_respondent = seq(20, 60, by = 5), p_surv = c(0.987, 0.967, 0.934, 0.908, 0.882, 0.835, 0.769, 0.669, 0.565), mean_age_parent = rep(27, 9), surv_date = 1998.5 ) om_plot_linearity(result) ## End(Not run)
Evaluates the sensitivity of orphanhood-based mortality estimates to
assumptions about the mean age of childbearing () by
re-estimating indices across a grid of additive offsets.
om_sensitivity(object = NULL, range_m = seq(-1.5, 1.5, 0.5), ...)om_sensitivity(object = NULL, range_m = seq(-1.5, 1.5, 0.5), ...)
object |
Optional. An object of class |
range_m |
Numeric vector of offsets (in years) applied to the baseline
mean age of childbearing. Default: |
... |
Additional arguments passed to |
An object of class OrphanhoodSensitivity, a named list with:
dataA data frame of estimates for each offset value, with columns
matching om_estimate_index()$estimates plus an additional
column Offset_M identifying the applied offset in years.
metaA named list of metadata: variable name, offset range, standard level, and estimation method.
plot.OrphanhoodSensitivity,
om_sensitivity_family, om_estimate_index
## Not run: result <- om_estimate_index( method = "luy", sex_parent = "Female", age_respondent = seq(20, 60, by = 5), p_surv = c(0.987, 0.967, 0.934, 0.908, 0.882, 0.835, 0.769, 0.669, 0.565), mean_age_parent = rep(27, 9), surv_date = 1998.5 ) sens <- om_sensitivity(result, range_m = seq(-2, 2, by = 0.5)) plot(sens, index = "30q30") ## End(Not run)## Not run: result <- om_estimate_index( method = "luy", sex_parent = "Female", age_respondent = seq(20, 60, by = 5), p_surv = c(0.987, 0.967, 0.934, 0.908, 0.882, 0.835, 0.769, 0.669, 0.565), mean_age_parent = rep(27, 9), surv_date = 1998.5 ) sens <- om_sensitivity(result, range_m = seq(-2, 2, by = 0.5)) plot(sens, index = "30q30") ## End(Not run)
Evaluates the sensitivity of orphanhood-based mortality estimates to the assumed age pattern of mortality by re-estimating indices across multiple model life table families.
om_sensitivity_family( object = NULL, type = c("UN", "CD", "All"), families = NULL, ... )om_sensitivity_family( object = NULL, type = c("UN", "CD", "All"), families = NULL, ... )
object |
Optional. An object of class |
type |
Character. Family system to evaluate. One of |
families |
Optional character vector of specific family names to test,
overriding |
... |
Additional arguments passed to |
An object of class OrphanhoodSensitivityFamily, a named list
with:
dataA data frame of estimates for each family, with columns matching
om_estimate_index()$estimates plus an additional column
Family identifying the model life table family.
metaA named list of metadata: variable name, families tested, standard level, family system name, and estimation method.
plot.OrphanhoodSensitivityFamily,
om_sensitivity, om_estimate_index
## Not run: result <- om_estimate_index( method = "luy", sex_parent = "Female", age_respondent = seq(20, 60, by = 5), p_surv = c(0.987, 0.967, 0.934, 0.908, 0.882, 0.835, 0.769, 0.669, 0.565), mean_age_parent = rep(27, 9), surv_date = 1998.5 ) sens_fam <- om_sensitivity_family(result, type = "UN") plot(sens_fam, index = "30q30") ## End(Not run)## Not run: result <- om_estimate_index( method = "luy", sex_parent = "Female", age_respondent = seq(20, 60, by = 5), p_surv = c(0.987, 0.967, 0.934, 0.908, 0.882, 0.835, 0.769, 0.669, 0.565), mean_age_parent = rep(27, 9), surv_date = 1998.5 ) sens_fam <- om_sensitivity_family(result, type = "UN") plot(sens_fam, index = "30q30") ## End(Not run)
OrphanhoodSensitivity ObjectsDisplays estimated mortality indices across reference years for each mean-age-of-childbearing offset, coloured from light (low offset) to dark (high offset).
## S3 method for class 'OrphanhoodSensitivity' plot(x, index = "30q30", ...)## S3 method for class 'OrphanhoodSensitivity' plot(x, index = "30q30", ...)
x |
An object of class |
index |
Character. Mortality index to plot. One of |
... |
Further arguments (currently unused). |
A ggplot object.
OrphanhoodSensitivityFamily ObjectsDisplays estimated mortality indices across reference years for each model life table family, distinguished by line type.
## S3 method for class 'OrphanhoodSensitivityFamily' plot(x, index = "30q30", ...)## S3 method for class 'OrphanhoodSensitivityFamily' plot(x, index = "30q30", ...)
x |
An object of class |
index |
Character. Mortality index to plot. One of |
... |
Further arguments (currently unused). |
A ggplot object.
OrphanhoodEstimate objectsPrint method for OrphanhoodEstimate objects
## S3 method for class 'OrphanhoodEstimate' print(x, ...)## S3 method for class 'OrphanhoodEstimate' print(x, ...)
x |
An object of class |
... |
Further arguments passed to |
Invisibly returns x.
OrphanhoodEstimate objectsSummary method for OrphanhoodEstimate objects
## S3 method for class 'OrphanhoodEstimate' summary(object, ...)## S3 method for class 'OrphanhoodEstimate' summary(object, ...)
object |
An object of class |
... |
Further arguments (currently unused). |
Invisibly returns object.