Repository for the generation of a synthetic population for the district of Den Haag Zuid-West in the year 2019. This project was undertaken at Utrecht University, The Netherlands, during 2022-2023 by Marco Pellegrino and a team of contributors.
The code in this repository utilizes the R library GenSynthPop created by Tabea Sonnenschein.
The work has been presented at the C-MAS workshop conference in London, 2023.
The repository provides the following functionalities:
Scripts in /src/format-datasets
are used to convert the input CBS demographic information into more convenient data frames, which are stored in the /data/processed
folder.
The script generate_synthetic_population.R
generates a synthetic population of individuals with demographic attributes, including:
- Gender: male, female
- Age: integer value
- Migration background: Dutch, Western, and non-Western
- Current education level: nothing/low/middle/high
- Education attainment: nothing/low/middle/high (Note: Dutch education level based on CBS classification)
- Children individuals living with at least one parent: true/false
- Car license ownership: true/false
The script generate_households.R
groups agents of the synthetic population into households and generates the following household-level attributes:
- Standardized 10% income group
- Car ownership
- Root folder: Contains the main scripts to generate the synthetic population and group them into households.
/src
: Contains helper functions and utility scripts./format-datasets
: Contains scripts to convert the raw datasets into processed datasets ready for use.
/data
:/raw
: CBS datasets to be processed by the scripts in/src
/processed
: Data sets ready-to-use, outputs of the scripts in/src/format-datasets
/evaluation
: Contains scripts to aggregate data for plots and tools to plot different distributions and comparisons.
This project was made possible thanks to the hard work and contributions from:
- Marco Pellegrino (Author)
- Jan de Mooij
- Tabea Sonnenschein
- Mehdi Dastani
- Dick Ettema
- Brian Logan
- Judith A. Verstegen
This repository is licensed under the GNU General Public License v3.0 (GPL-3.0). For more details, see the LICENSE file.