Clicky

SICSS-Covenant:Using gridded population to gain spatial insights in R

I have been invited to present at the Summer Institute for Computational Social Sciences in University of Covenant. My talks starts is about gridded population as a tool to link demographics and geography. It starts with a global overview of the definition, production and use of this innovative data and pursues with a hands-on in R to gain spatial insights on demography in Nigeria.

Edith Darin true
06-24-2022

Extract from the github repo that contains the session’s material.

Linking demographics and geography: Using gridded population to gain spatial insights in R

Introduction

Access to high-resolution population counts is key for local, national and international decision-making and intervention. It supports data-driven planning of critical infrastructures, such as schools, health facilities and transportation networks.

WorldPop has developed modelling techniques to estimate population in grid cells of 100m by 100m by disaggregating census-based population totals for the entire world, leveraging the growing availability of products derived from satellite imagery. This level of detail offers the advantage of flexible aggregation of the population estimates within different administrative and functional units, for instance, school catchment areas and health zones.

This session will cover the notion of gridded population, a data format at the crossroad of demography and geography. We will then have a brief overview of openly available satellite-imagery-based products that can be used for modelling gridding population and beyond, such as settlement maps. Finally, we will have some hands-on to extract information from a gridded population covering the following R packages for geospatial analysis: sf (Pebesma, E., 2018), raster (Hijmans, R., 2021), and tmap (Tennekes, M., 2018).

Challenge

We will study the question: How many women of childbearing age are struggling to access maternal health services?

Concepts

This tutorial covers the concepts of:

Contents

On github is stored the raw material for this tutorial. The script for_students.R contains the workflow with the questions. The script teaching.R contains the workflow with the answers. The powerpoint SICSS_20220624_griddedPop.pptx contains the presentation.

Data used

For that purpose, we will need to access three data sources:

  1. Population data from the Bottom-up gridded population estimates for Nigeria, version 2.0, produced jointly by WorldPop and the National Population Commission of Nigeria and accessible here,

  2. Health facilities locations produced by GRID3 Nigeria and accessible here,

  3. Local Government Area operational boundaries released by GRID3 Nigeria and accessible here On github the three data file are stored for this tutorial.

## Practical

library(tidyverse) #R library to manipulate table data
library(tmap) # R library to plot interactive maps
library(kableExtra) # R library for nice tables

tmap_mode('view') # set tmap as interactive
tmap_options(check.and.fix = TRUE) 

Defining the study area ————————————————-

library(sf) # R library to manipulate spatial data

We load the vector file of administrative regions in Nigeria

lga <- st_read(
  paste0(
    data_path,
    '/GRID3_Nigeria_-_Local_Government_Area_Boundaries/GRID3_Nigeria_-_Local_Government_Area_Boundaries.shp'))
Reading layer `GRID3_Nigeria_-_Local_Government_Area_Boundaries' from data source `C:\Users\ecd1u18\Documents\SICSS-covenant-gridded-population\data\GRID3_Nigeria_-_Local_Government_Area_Boundaries\GRID3_Nigeria_-_Local_Government_Area_Boundaries.shp' 
  using driver `ESRI Shapefile'
Simple feature collection with 774 features and 7 fields
Geometry type: MULTIPOLYGON
Dimension:     XY
Bounding box:  xmin: 2.692613 ymin: 4.270204 xmax: 14.67797 ymax: 13.88571
Geodetic CRS:  WGS 84
lga %>% 
      glimpse()
Rows: 774
Columns: 8
$ OBJECTID   <int> 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15~
$ lga_code   <chr> "10001", "10002", "10003", "10004", "10005", "100~
$ state_code <chr> "DE", "DE", "DE", "DE", "DE", "DE", "DE", "DE", "~
$ lga_name_x <chr> "Aniocha North", "Aniocha South", "Bomadi", "Buru~
$ mean       <dbl> 91927.45, 193913.27, 32604.42, 53159.27, 153016.5~
$ Shape__Are <dbl> 0.033182160, 0.070862318, 0.016922270, 0.14636025~
$ Shape__Len <dbl> 0.8457545, 1.2001197, 1.0004980, 2.4157890, 1.068~
$ geometry   <MULTIPOLYGON [°]> MULTIPOLYGON (((6.438156 6...., MULT~

We plot using tmap interactive functions