Extract population counts by age and sex for a given country and time period can choose process = "census", "estimate", or "register"

DDextract_PopCounts(
  locid,
  process = c("census", "estimate", "register"),
  start_year,
  end_year,
  DataSourceShortName = NULL,
  DataSourceYear = NULL
)

Arguments

locid

The Location Id for each country. Run DemoTools::get_locations() to get information about available locations. The ids are indicated in the PK_LocID variable.

process

The data collection process i.e. Census (census), Estimate (estimate) or Register (register).

start_year

The minimum year for the data available for each country

end_year

The maximum year for the data available for each country

DataSourceShortName

NULL.

DataSourceYear

NULL.

Value

A dataset showing population counts for each location, process, year, sex and age label.

Examples

if (FALSE) {
dd_extract <- DDextract_PopCounts(404, #Kenya
                                   process = c("census","estimate","register"),
                                   1950,
                                   2050,
                                   DataSourceShortName = NULL,
                                   DataSourceYear = NULL)
}