twoHelixestwoHelixes Start free

Datasets / Our World in Data (CC BY 4.0); built by scripts/build-world-fixtures.sh

World health and longevity

Life expectancy, child mortality, fertility, obesity and smoking by country and year. Empty cells are missing, never zero.

8,229 rows8 columns Our World in Data (CC BY 4.0); built by scripts/build-world-fixtures.sh

Worked examples

Each of these is a real run: the pipeline picked the columns, shaped the rows and chose the form. Open the trace to see what it decided and why.

Highest life expectancy, latest year per country

Each country contributes its own latest observed value, so the ranking is not distorted by the different years in which each series ends.

Highest life expectancy050100150MonacoJapanFrench PolynesiaAustraliaSpainReunionMaltaMacaoLife Expectancy
which countries have the highest life expectancy in the latest year? — 25 rows charted from 8,229, drawn as a hbar
How it decided
Finding the data11 ms

World health and longevity: 8,229 rows, 8 columns. country, year and life_expectancy; missing values are dropped, never read as zero.

Shaping the data16 ms

8,229 rows in, 25 out across 2 columns. Each country contributes its own latest observed value, so the ranking is not distorted by the different years in which each series ends.

Choosing the chart12 ms

hbar. A ranking of long country names is a horizontal bar chart, capped at twenty-five rows so the top of the distribution stays readable.

Applying defaults1 ms

Palette, spacing, axis titles and legend placement applied. 0 issues found.

Change in life expectancy since 1990

Change is measured per country between its 1990 value and its latest observed value, so countries with different coverage are still compared on their own history.

Life expectancy change since 19900102030South SudanMalawiEthiopiaRwandaEritreaZambiaGuinea-BissauCambodiaChange
how has life expectancy changed since 1990 by country? — 25 rows charted from 8,229, drawn as a hbar
How it decided
Finding the data13 ms

World health and longevity: 8,229 rows, 8 columns. country, year and life_expectancy in 1990 and in the latest year per country.

Shaping the data26 ms

8,229 rows in, 25 out across 4 columns. Change is measured per country between its 1990 value and its latest observed value, so countries with different coverage are still compared on their own history.

Choosing the chart8 ms

hbar. A per-country before-and-after difference is one bar per country, sorted by the size of the change.

Applying defaults1 ms

Palette, spacing, axis titles and legend placement applied. 0 issues found.

Child mortality against fertility, latest year per country

Each country is one point at its latest observed pair, so the shape of the relationship across countries is visible without mixing years.

Child mortality against fertility025810120.9162.2811.4861.5051.4651.7491.714Fertility Rate
is child mortality related to fertility in the latest year? — 200 rows charted from 8,229, drawn as a scatter
How it decided
Finding the data9 ms

World health and longevity: 8,229 rows, 8 columns. fertility_rate and child_mortality_pct at the latest year per country; missing pairs are dropped.

Shaping the data8 ms

8,229 rows in, 200 out across 2 columns. Each country is one point at its latest observed pair, so the shape of the relationship across countries is visible without mixing years.

Choosing the chart1 ms

scatter. Two measures with no time axis is a scatter; one point per country keeps every country visible.

Applying defaults1 ms

Palette, spacing, axis titles and legend placement applied. 0 issues found.

Life expectancy over time for five countries

Five named countries with very different starting points on one year axis show how their paths diverge over the same period.

Life expectancy by country020406080199019931996199920022005200820112014201720202023YearSwitzerlandCanadaPortugalCambodiaZimbabwe
how did life expectancy trend for Canada, Switzerland, Zimbabwe, Portugal and Cambodia? — 170 rows charted from 8,229, drawn as a line
How it decided
Finding the data8 ms

World health and longevity: 8,229 rows, 8 columns. year, country and life_expectancy for the five named countries; missing years are dropped.

Shaping the data5 ms

8,229 rows in, 170 out across 3 columns. Five named countries with very different starting points on one year axis show how their paths diverge over the same period.

Choosing the chart9 ms

line. A measure over time with one line per country, capped at five series so the lines stay distinguishable.

Applying defaults1 ms

Palette, spacing, axis titles and legend placement applied. 0 issues found.

Schema

8 columns, typed as the pipeline sees them — which is how it knows what can go on a time axis and what can be summed.

Column TypeExample
countrytextAruba
codetextABW
yearnumber1990
life_expectancynumber72.546
child_mortality_pctnumber18.14
fertility_ratenumber2.345
obesity_pctnumber1.7234
smoking_pctnumber38.0

First 8 rows

countrycodeyearlife_expectancychild_mortality_pctfertility_rateobesity_pctsmoking_pct
ArubaABW199072.546nan2.345nannan
ArubaABW199172.5921nan2.362nannan
ArubaABW199272.7174nan2.353nannan
ArubaABW199372.7767nan2.331nannan
ArubaABW199472.796nan2.298nannan
ArubaABW199572.8322nan2.288nannan
ArubaABW199672.8561nan2.233nannan
ArubaABW199772.904nan2.138nannan