# Kenya Population Analysis
## Project description
This project processes WorldPop gridded population rasters into a county
level dataset for Kenya and provides a dashboard for exploring it.
The pipeline downloads age and sex structured population estimates for 2021
to 2025, validates them, aggregates them from 1km grid cells to the 47
counties, and calculates demographic indicators used in health planning. No
file is downloaded or edited by hand. Running one command reproduces the
full output.
Outputs:
- `data/processed/kenya_population_by_county.csv`, one row per county per
year with population counts, dependency ratios and age structure shares
- `data/processed/kenya_population_age_sex.csv`, the same data broken down
by five year age band and sex, used by the age pyramid in the dashboard
- `data/processed/kenya_counties.geojson`, the 47 county boundaries used in
the aggregation, saved so the map and the numbers stay consistent
- `logs/validation_log.txt`, a record of the checks run and the decisions
taken about the data
- A Streamlit dashboard
## Public health context
Age structure determines what a health system has to provide, and Kenya's
counties vary enough that a national average is not much use for planning.
Children under five drive demand for routine immunisation, growth
monitoring, nutrition programmes and paediatric care. A county with a high
share of under fives needs a different service mix and different staffing
from one with a low share.
The population aged 65 and over drives demand for chronic disease
management, particularly hypertension and diabetes, and for services that
most primary facilities in Kenya were not originally set up to deliver.
This group is small nationally but growing, and it is concentrated in some
counties more than others.
The dependency ratio compares the dependent age groups to the working age
population that supports them through the tax base and household income. A
high ratio means more people needing care relativ …