ddm(X, minA = 15, maxA = 75, minAges = 8, exact.ages = NULL,
eOpen = NULL, deaths.summed = FALSE)
data.frame
with columns, $pop1
, $pop2
, $deaths
, $date1
, $date2
, $age
, $sex
, and $cod
(if there are more than 1 region/sex/intercensal period).TRUE
). By default we assume FALSE
, i.e. that the average annual was given.$cod
, $ggb
, $bh1
, $bh2
, $lower
, and $upper
.plot.ggb()
, when working with a single year/sex/region of data. The automatic age-range determination feature of this function tries to implement an intuitive way of picking ages that follows the advice typically given for doing so visually. We minimize the square of the average squared residual between the fitted line and right term.If you want coverage estimates for a variety of partitions (intercensal periods/regions/by sex), then stack them, and use a variable called $cod
with unique values for each data partition. If data is partitioned using the variable $cod
, then the age range automatically determined might not be the same for each partition. If user-specified, (using a vector of exact.ages
) the age ranges will be the same for all partitions. If you want to specify particular age ranges for each data partition, then you'll need to loop it somehow.All three methods require time points of the two censuses. Census dates can be given in a variety of ways: 1) (preferred) using Date
classes, and column names $date1
and $date2
(or an unambiguous character string of the date, like, "1981-05-13"
) or 2) by giving column names "day1","month1","year1","day2","month2","year2"
containing respective integers. If only year1
and year2
are given, then we assume January 1 dates. If year and month are given, then we assume dates on the first of the month. Different values of $cod
could indicate sexes, regions, intercensal periods, etc. The $deaths
column should refer to the average annual deaths for each age class in the intercensal period. Sometimes one uses the arithmetic average of recorded deaths in each age, or simply the average of the deaths around the time of census 1 and census 2.
The synthetic extinct generation methods require an estimate of remaining life expectancy in the open age group of the data provided. This is produced using a standard reference to the Coale-Demeny West model life tables. That is a place where things can be improved.
Hill K. Estimating census and death registration completeness. Asian and Pacific Population Forum. 1987; 1:1-13.
Hill K, You D, Choi Y. Death distribution methods for estimating adult mortality: sensitivity analysis with simulated data errors. Demographic Research. 2009; 21:235-254.
Brass, William, 1975. Methods for Estimating Fertility and Mortality from Limited and Defective Data, Carolina Population Center, Laboratory for Population Studies, University of North Carolina, Chapel Hill.
Preston, S. H., Coale, A. J., Trussel, J. & Maxine, W. Estimating the completeness of reporting of adult deaths in populations that are approximately stable. Population Studies, 1980; v.4: 179-202
# The Mozambique data
res <- ddm(Moz)
head(res)
# The Brasil data
BM <- ddm(BrasilMales)
BF <- ddm(BrasilFemales)
head(BM)
head(BF)
Run the code above in your browser using DataLab