8000 GitHub - statistik-aargau/propop: Project Population Development
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

statistik-aargau/propop

Repository files navigation

Welcome to the propop package

Lifecycle: stable Project Status: Active - The project has reached a stable, usable state and is being actively developed. R build status

Overview

The goal of propop is to create population projections using the cohort component method (see e.g., Preston, Guillot, and Heuveline, 2000; Statistik Aargau, 2025a; Statistik Aargau, 2025b). For a breakdown of the components, see this vignette.

The package was developed for use with projection scenarios from the Swiss Federal Statistical Office (FSO). The current scenarios are available for the years 2024-2055. As starting population, you can eithe 9164 r use population data from the FSO or your own population data.

propop uses the same matrix calculation method as the FSO (2020; only available in French) and therefore reveals almost identical results (see vignette Evaluate projections). The package can be used to project the development of different demographic groups for different scenarios and at different spatial levels (e.g., single canton or municipalities within a canton).

While the package was primarily designed for use with FSO input data (e.g., mortality rates), it should in principle also work for other contexts (e.g., custom input data). However, it is important to provide the required input data in the specified form.

Installation

To install the current github version of the package, make sure you have devtools installed and type:

devtools::install_github("statistik-aargau/propop")

Vignettes

The package includes four vignettes.

Features, limitations, future plans

  • propop::propop() works with either two nationalities (usually Swiss vs. non-Swiss nationals) or without distinguishing between nationalities.
  • However, propop::propop() currently requires 1-year age classes (0-100+) and two genders.
  • The FSO projections are only published in five-year intervals, the most recent ones being based on population records from 2023. propop enables you to run projections with more recent population records.
  • This package was developed for use with FSO parameters (e.g., mortality rate, or emigration rate). Most parameters are only available for cantons and the whole of Switzerland. If you wish to run projections at smaller scales (e.g., districts), you need to prepare the parameters for each spatial entity before running the projection. This vignette includes tips of how to prepare your input data.
  • Similarly, if you wish to adjust parameters (e.g., mortality rates that vary between subregions), you need to prepare the parameters accordingly.
  • propop::propop()offers the possibility to account for varying subregional migration patterns and migration between subregions. However, before using this feature, users must adjust or calculate the required parameters (see this vignette).
  • Custom parameters (e.g., consideration of sub-cantonal spatial entities, adjustments to reflect regional differences, or addition of subregional migration parameter) can be passed through the parameters object to propop::propop().
  • The FSO uses additional ex-post adjustments to ensure that all the sums involving different cantons add up, which leads to some differences between the projections from the FSO and propop.
  • There are also possible future features that could increase the accuracy of the projections. For example, considering the attractiveness of municipalities or planned housing developments could help to better explain why population growth varies between municipalities.

If you are interested in contributing to these or other developments, please get in touch with the package maintainer.

Quick example

To run propop::propop() with the example data included in the package (canton of Aargau), use the following code:

library(propop)
projection_canton_2030 <- propop(
parameters = fso_parameters,
year_first = 2024,
year_last = 2030,
population = fso_population,
subregional = FALSE,
binational = TRUE)
0