Numbers you can defend
Who gets left behind?
Rural against urban, women against men, in the same year.
Lesson 4 of 6 · Analyse it in Python
Try it yourself
- Python, after
import undata as unCOMPLETION = "undata/sdg/SE_TOT_CPLR.EDUCATION_LEVEL--ISCED11_1" un.breakdowns(COMPLETION) gap = un.gap(COMPLETION, ["Chad", "Niger", "Mali", "Nigeria", "Ghana", "Bangladesh", "Nepal"], by="urbanization") un.chart(gap, "rural-urban-gap.png") - Open the rural-urban gap use case in Colab
Remember: Compare two groups within the same year, or the gap is one survey against another.
Transcript
- National averages hide people. Leaving no one behind means looking at the gaps: between towns and villages, women and men, the poorest and the richest. Here is how to measure one, properly.
- Start by asking what an indicator can be split by. Here, primary school completion. un.breakdowns lists every breakdown the agency publishes: by sex, by rural and urban area, and by wealth, in fifths.
- un.gap compares two groups across countries. Choose the breakdown, here urbanization. For each country it takes the latest year in which both groups have a value, so the gap is never one survey against another. You get both values, the ratio, and the difference.
- In Chad, 19 percent of rural children finish primary school, against 55 percent in towns. A rural child is about a third as likely to finish. Niger and Mali show the same pattern. But in Bangladesh, rural children are slightly ahead, and Nepal is close to parity. So a gap like Chad’s is not inevitable.
- un.chart sorts the countries by the gap, and prints the ratio and the year beside each one. Chad’s figure is from 2019; the others are more recent, and the chart says so.
- And the summary states the finding: where the gap is widest, and which countries are at parity. The sentence in your report comes straight from the data.
- Change one word to compare girls and boys, or the poorest fifth with the richest, wherever the agency publishes that breakdown.
- Gaps measured like with like, in the same year. Next: the safeguards that make these numbers defensible.