DataBrighten

    Dimension 4.1: Censuses and Surveys - Censuses only

    3,800 × 6rows × columns: 190 countries, 2004 to 2023

    Real data: World Bank, Statistical Performance Indicators, indicator SPI.DIM4.1.CEN.INDEX, retrieved 19 November 2026. Values are as published; we only reshaped the file.

    textnumberdateyes/no
    Rows3,800country-year values
    Countries190with at least one value
    Years2004 – 202320 years with data
    LicenceCC BY 4.0credit the World Bank

    What it measures

    Average score Census and Survey Indicators indicators. Availability of recent censuses and surveys covering broad areas. The following censuses and surveys are considered: Population & Housing census, Agriculture census, Business/establishment census, Household Survey on income/ consumption/ expenditure/ budget/ Integrated Survey, Agriculture survey, Labor Force Survey, Health/Demographic survey, Business/establishment survey. Source: NSO websites, World Bank microdata library, ILO microdata library, IHSN microdata librar

    The numbers in 2023

    In 2023, 190 countries have a value. At the top, 83 countries tie at 1 (e.g. Albania, Angola, Argentina); at the bottom, 4 countries tie at 0 (e.g. Congo, Dem. Rep., Eritrea, Iraq). The median country value is 0.833.

    Highest, 2023

    Ties are listed A to Z.

    #CountryValue
    1Albania1
    2Angola1
    3Argentina1
    4Australia1
    5Austria1
    6Azerbaijan1
    7Bangladesh1
    8Belarus1
    9Belgium1
    10Belize1

    Lowest, 2023

    Ties are listed A to Z.

    #CountryValue
    1Somalia, Fed. Rep.0
    2Iraq0
    3Eritrea0
    4Congo, Dem. Rep.0
    5Yemen, Rep.0.167
    6Syrian Arab Republic0.167
    7Sudan0.167
    8South Sudan0.167
    9Sao Tome and Principe0.167
    10Papua New Guinea0.167
    How many countries report, by decade
    DecadeMost countries in one year
    2000s190
    2010s190
    2020s190

    First rows

    dimension-4-1-censuses-and-surveys-censuses-only.csv

    countrytextiso3textregiontextincome_grouptextyearnumbervaluenumber
    AfghanistanAFGMiddle East, North Africa, Afghanistan & PakistanLow income20040.333333333333333
    AfghanistanAFGMiddle East, North Africa, Afghanistan & PakistanLow income20050.333333333333333
    AfghanistanAFGMiddle East, North Africa, Afghanistan & PakistanLow income20060.333333333333333
    AfghanistanAFGMiddle East, North Africa, Afghanistan & PakistanLow income20070.333333333333333
    AfghanistanAFGMiddle East, North Africa, Afghanistan & PakistanLow income20080.333333333333333
    AfghanistanAFGMiddle East, North Africa, Afghanistan & PakistanLow income20090.333333333333333
    AfghanistanAFGMiddle East, North Africa, Afghanistan & PakistanLow income20100.333333333333333
    AfghanistanAFGMiddle East, North Africa, Afghanistan & PakistanLow income20110.333333333333333

    Data dictionary

    ColumnTypeMeaning
    countrytextCountry or economy, World Bank name
    iso3textISO 3166-1 alpha-3 code
    regiontextWorld Bank region
    income_grouptextWorld Bank income group
    yearnumberCalendar year of the value
    valuenumberDimension 4.1: Censuses and Surveys - Censuses only, exactly as the World Bank API returns it (not rounded)

    Only country-years with a value are in the long file; blank cells in the wide file mean no value was published.

    Practice questions

    answers computed from the file

    Which country has the highest value in 2023?

    There is a tie: 83 countries share the highest value, 1 (for example Albania, Angola, Argentina).

    Excel (on the long CSV: E = year, F = value)

    =FILTER(A2:A100000,(E2:E100000=2023)*(F2:F100000=MAXIFS(F2:F100000,E2:E100000,2023)))

    SQL (table wb = the CSV)

    SELECT country, value FROM wb WHERE year = 2023
      AND value = (SELECT MAX(value) FROM wb WHERE year = 2023);

    pandas (df = pd.read_csv("dimension-4-1-censuses-and-surveys-censuses-only.csv"))

    y = df[df.year == 2023]
    y[y.value == y.value.max()][["country", "value"]]

    File: dimension-4-1-censuses-and-surveys-censuses-only.csv

    How many countries report a value for 2023?

    190 of the 217 economies in the file's country list.

    Excel (on the long CSV: E = year, F = value)

    =COUNTIF(E2:E100000,2023)

    SQL (table wb = the CSV)

    SELECT COUNT(*) FROM wb WHERE year = 2023;

    pandas (df = pd.read_csv("dimension-4-1-censuses-and-surveys-censuses-only.csv"))

    (df.year == 2023).sum()

    File: dimension-4-1-censuses-and-surveys-censuses-only.csv

    What is the median across countries in 2023?

    0.833 (median of the 190 country values; not a World Bank aggregate).

    Excel (on the long CSV: E = year, F = value)

    =MEDIAN(FILTER(F2:F100000,E2:E100000=2023))

    SQL (table wb = the CSV)

    -- SQLite has no MEDIAN(); this picks the middle value(s)
    SELECT AVG(value) FROM (SELECT value FROM wb WHERE year = 2023 ORDER BY value
      LIMIT 2 - (SELECT COUNT(*) FROM wb WHERE year = 2023) % 2
      OFFSET (SELECT (COUNT(*) - 1) / 2 FROM wb WHERE year = 2023));

    pandas (df = pd.read_csv("dimension-4-1-censuses-and-surveys-censuses-only.csv"))

    df[df.year == 2023]["value"].median()

    File: dimension-4-1-censuses-and-surveys-censuses-only.csv

    Which country rose the most between 2013 and 2023?

    Angola: from 0.333 to 1, a rise of 0.667 (out of 190 countries with both years).

    Excel (on the long CSV: E = year, F = value)

    Use the wide file (dimension-4-1-censuses-and-surveys-censuses-only-wide.csv): add a column = [2023] - [2013], then sort it largest to smallest.

    SQL (table wb = the CSV)

    SELECT a.country, b.value - a.value AS rise FROM wb a JOIN wb b ON a.iso3 = b.iso3
    WHERE a.year = 2013 AND b.year = 2023 ORDER BY rise DESC LIMIT 1;

    pandas (df = pd.read_csv("dimension-4-1-censuses-and-surveys-censuses-only.csv"))

    w = df.pivot(index="country", columns="year", values="value")
    (w[2023] - w[2013]).dropna().nlargest(1)

    File: dimension-4-1-censuses-and-surveys-censuses-only.csv

    Which year has the most countries reporting?

    2023, with 190 countries.

    Excel (on the long CSV: E = year, F = value)

    Make a pivot table: year in Rows, Count of value in Values, then sort by the count.

    SQL (table wb = the CSV)

    SELECT year, COUNT(*) AS n FROM wb GROUP BY year ORDER BY n DESC, year DESC LIMIT 1;

    pandas (df = pd.read_csv("dimension-4-1-censuses-and-surveys-censuses-only.csv"))

    df.groupby("year").size().sort_values(ascending=False).head(1)

    File: dimension-4-1-censuses-and-surveys-censuses-only.csv