Demographic Methods for data Evaluation,Transformation, and Adjustment: The
DemoTools R package
Tim Riffe
8-April-2020
Objective
Scripted processing of country input data using a standard set oftools.
I input selection from DemoData API (DDSQLtools)I sequences of demographic methods to fill the Lexis spaceI rule-based automatic (default) selection of methods and
execution orderI full reproducibility
DemoTools
An open collection of classic demographic methods including:
I common demographic operations and utilities
I specific demographic methods toI evaluateI adjustI transform
Evaluation
I Age structure check_heaping_*():I Digit attraction: Myers, Whipple, Bachi, Spoorenberg, Coale Li,
Kannisto, Jdanov, NoumbissiI Regular decadal patterns: Roughness, Sawtooth /\/\/\/\/
I Consistency: census survival ratio errors, age-ratio andsex-ratio scoring, difference and dissimilarity indices
Adjustment
Graduation
I graduate(): Sprague, Beers, Splines, PCLM (ungroup)
Smoothing
I smooth_age5(): Arriaga, Carrier-Farrag, UN,Karup-King-Newton, Strong, and others
Transformation
I binning, scaling, truncation
I time-shifting: interp_*() age-period, age-cohortinterpolation, cohort component interpolation
I lifetables: lt_*() abridged, single, extrapolation(MortalityLaws), rule and model-based (Wilmoth, *Clark,etc)
In the works
I more Lexis filling methods (reverse surival, cohort componentinterpolation, consistency adjustments)
I rule-based methods selection (needs more evaluation andchecks)
I faster lifetables
I educational materials and workshops
Major contributors
Monica Alexander Jorge Cimentada Sean Fennell
Jose Manuel Aburto Ilya Kashnitsky Marius Pascariu
Acknowlegements
Bill & Melinda Gates Foundation, UNPD, Patrick Gerland, RafaelaOliveira, Erik Vickstrom
https://github.com/timriffe/DemoTools