Cohorts between two censuses are interpolated using a cohort component approach.

interp_coh(
  c1,
  c2,
  date1,
  date2,
  age1 = 1:length(c1) - 1,
  age2 = 1:length(c2) - 1,
  dates_out = NULL,
  lxMat = NULL,
  age_lx = NULL,
  dates_lx = NULL,
  births = NULL,
  years_births = NULL,
  location = NULL,
  sex = "both",
  midyear = FALSE,
  verbose = TRUE,
  ...
)

Arguments

c1

numeric vector. The first (left) census in single age groups

c2

numeric vector. The second (right) census in single age groups

date1

reference date of c1`. Either a Date class object or an unambiguous character string in the format "YYYY-MM-DD".

date2

reference date of c2`. Either a Date class object or an unambiguous character string in the format "YYYY-MM-DD".

age1

integer vector. single ages of c1

age2

integer vector. single ages of c2

dates_out

vector of desired output dates coercible to numeric using dec.date()

lxMat

numeric matrix containing lifetable survivorship, l(x). Each row is an age group and each column a time point. At least two intercensal time points needed.

age_lx

integer vector. Age classes in lxMat

dates_lx

date, character, or numeric vector of the column time points for lxMat. If these are calendar-year estimates, then you can choose mid-year time points

births

integer vector. Raw birth counts for the corresponding (sub)-population, one value per each year of the intercensal period including both census years. The first and last years should include all births in the given year; don't discount them in advance.

years_births

numeric vector of calendar years of births.

location

UN Pop Division LocName or LocID

sex

character string, either "male", "female", or "both"

midyear

logical. FALSE means all Jan 1 dates between date1 and date2 are returned. TRUE means all July 1 intercensal dates are returned.

verbose

logical. Shall we send informative messages to the console?

...

optional arguments passed to

Details

The basic approach is to i) align the censuses to single-year cohorts by blending adjacent ages assuming that the birthdays in each age group are uniformly distributed through the year ii) decrement the first census forward within cohorts using period-cohort survival probabilities calculated from (supplied or downloaded) l(x) values, iii) redistribute the residual at the time of the second census uniformly over time within cohorts. These steps are always done on Jan 1 reference dates. If midyear = TRUE, then we do within-age band arithmetic interpolation to July 1 reference dates.

See also

interp

Examples

if (FALSE) { interp_coh( location = "Russian Federation", sex = "male", c1 = pop1m_rus2002, c2 = pop1m_rus2010, date1 = "2002-10-16", date2 = "2010-10-25", age1 = 0:100, births = c(719511L, 760934L, 772973L, 749554L, 760831L, 828772L, 880543L, 905380L, 919639L) ) }