DataBrighten

    Railways, goods transported (million ton-km)

    2,165 × 6rows × columns: 113 countries, 1995 to 2021

    Real data: World Bank, World Development Indicators, indicator IS.RRS.GOOD.MT.K6, retrieved 19 November 2026. Values are as published; we only reshaped the file.

    textnumberdateyes/no
    Rows2,165country-year values
    Countries113with at least one value
    Years1995 – 202127 years with data
    LicenceCC BY 4.0credit the World Bank

    What it measures

    Goods transported by railway are the volume of goods transported by railway, measured in metric tons times kilometers traveled.

    Limits and exceptions (World Bank note)

    Data for transport sectors are not always internationally comparable. Unlike for demographic statistics, national income accounts, and international trade data, the collection of infrastructure data has not been "internationalized." The data from UIC is based on voluntary reporting by railway companies, and can show drastic increases or decreases for some of the years due to lack of reporting by some of the companies in that country.

    The numbers in 2020

    In 2020, 62 countries have a value. The highest is Russian Federation (2.54 million); the lowest is Albania (26.04). The median country value is 5,756. The World Bank's World aggregate for 2007 is 5,646.

    Top 10 countries, 2020

    million ton-km

    Source: World Bank, IS.RRS.GOOD.MT.K6, retrieved 19 November 2026. Computed from railways-goods-transported-million-ton-km.csv.

    Highest, 2020

    #CountryValue
    1Russian Federation2.54 million
    2United States2.10 million
    3India707,665
    4Australia447,435
    5Canada444,032
    6Kazakhstan302,156
    7Ukraine175,587
    8Germany108,406
    9Mexico86,224
    10Poland51,096

    Lowest, 2020

    #CountryValue
    1Albania26.04
    2Ireland74
    3Luxembourg162
    4Congo, Dem. Rep.171.3
    5Tajikistan274
    6Tunisia334.8
    7North Macedonia342
    8Gabon409
    9Greece555
    10Moldova599
    How many countries report, by decade
    DecadeMost countries in one year
    1990s98
    2000s95
    2010s81
    2020s62

    World aggregate by year

    As published by the World Bank (in the regions file, not the country file).

    YearWorld
    20075,646
    20064,893
    20054,037
    20043,904
    20033,274
    20023,422
    20013,942
    20002,264
    19992,106
    19982,594
    19972,288
    19962,085

    By region, 2020

    World Bank regionValue
    North America1.27 million
    Europe & Central Asia7,624

    First rows

    railways-goods-transported-million-ton-km.csv

    countrytextiso3textregiontextincome_grouptextyearnumbervaluenumber
    AlbaniaALBEurope & Central AsiaUpper middle income199553
    AlbaniaALBEurope & Central AsiaUpper middle income199642
    AlbaniaALBEurope & Central AsiaUpper middle income199723
    AlbaniaALBEurope & Central AsiaUpper middle income199825
    AlbaniaALBEurope & Central AsiaUpper middle income199926
    AlbaniaALBEurope & Central AsiaUpper middle income200028
    AlbaniaALBEurope & Central AsiaUpper middle income200119
    AlbaniaALBEurope & Central AsiaUpper middle income200221

    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
    valuenumberRailways, goods transported (million ton-km), 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 2020?

    Russian Federation, with 2.54 million.

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

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

    SQL (table wb = the CSV)

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

    pandas (df = pd.read_csv("railways-goods-transported-million-ton-km.csv"))

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

    File: railways-goods-transported-million-ton-km.csv

    How many countries report a value for 2020?

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

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

    =COUNTIF(E2:E100000,2020)

    SQL (table wb = the CSV)

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

    pandas (df = pd.read_csv("railways-goods-transported-million-ton-km.csv"))

    (df.year == 2020).sum()

    File: railways-goods-transported-million-ton-km.csv

    What is the median across countries in 2020?

    5,756 (median of the 62 country values; not a World Bank aggregate).

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

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

    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 = 2020 ORDER BY value
      LIMIT 2 - (SELECT COUNT(*) FROM wb WHERE year = 2020) % 2
      OFFSET (SELECT (COUNT(*) - 1) / 2 FROM wb WHERE year = 2020));

    pandas (df = pd.read_csv("railways-goods-transported-million-ton-km.csv"))

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

    File: railways-goods-transported-million-ton-km.csv

    Which country rose the most between 2010 and 2020?

    Russian Federation: from 2.01 million to 2.54 million, a rise of 533,520 (out of 60 countries with both years).

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

    Use the wide file (railways-goods-transported-million-ton-km-wide.csv): add a column = [2020] - [2010], 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 = 2010 AND b.year = 2020 ORDER BY rise DESC LIMIT 1;

    pandas (df = pd.read_csv("railways-goods-transported-million-ton-km.csv"))

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

    File: railways-goods-transported-million-ton-km.csv

    Which year has the most countries reporting?

    1997, with 98 countries. (Later years are still filling in as countries report.)

    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("railways-goods-transported-million-ton-km.csv"))

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

    File: railways-goods-transported-million-ton-km.csv