Home

MPIDR Technical Report

An R-script for the assessment of the cross-sectional and the longitudinal components of a difference between two values of an aggregate demographic measure by contour replacement

Jdanov, D. A., Shkolnikov, V. M.

MPIDR Technical Report TR-2014-003, 6 pages (December 2014).
Rostock, Max Planck Institute for Demographic Research

Abstract

An algorithm for the contour decomposition of differences between two values of an aggregate demographic measure is realized in R. The contour replacement algorithm is an extension of the stepwise replacement algorithm. It allows us to split the cross-sectional difference at a later time point by age, and to further split it through contributions of the initial conditions and of the trend. The input arguments are matrices of event rates for two populations under comparison. Each of the matrices contains two vectors of event rates for the initial and the final time points. The aggregate measure is computed by an external R function.

Socialize