A climate policy team wants one map for a 2010-to-2022 comparison of CO2 emissions per person. The indicator table has missing country-years and one unusually large fall in a small island economy. If the full range drives the colour ramp, changes elsewhere barely register. The map must preserve the actual numbers for audit while declaring its visual cap.
Use /data/countries.geojson (Natural Earth country polygons) and /data/indicators.geojson (World Bank WDI country values carried by representative points). In the Python runner, inputs are mounted at /data/<dataset id>.geojson; assign a GeoDataFrame to result and write no file.
Join by iso_a3, not by country name or point-in-polygon. Keep only countries with numeric values in both co2_pc_2010 and co2_pc_2022. Compute delta_t = co2_pc_2022 - co2_pc_2010 in tonnes CO2 equivalent per person, preserving at least three decimals. Positive means higher per-capita emissions in 2022; negative means lower. Also produce display_delta_t = max(-5, min(5, delta_t)) for a legible diverging map, and integer increase_flag equal to 1 if the true delta is positive, else 0. Keep iso_a3, name, both original values, true delta, display delta, flag and country polygon geometry.
The country polygons come from the platform's validated Natural Earth layer, with Morocco represented as one country and no internal southern border. Do not replace it with another basemap. The indicator points are tabular carriers, not observation stations. Report the display cap in the legend and preserve the true delta_t in each feature so a reader can inspect an outlier. This is a two-date comparison of one per-capita CO2 indicator excluding land-use change and forestry; it is neither total national emissions nor a causal verdict on policy.
/data/countries.geojson — EPSG:4326; the geometry is in geometry (Polygon / MultiPolygon).
| column | type | meaning |
|---|---|---|
country_id | string | CO- plus the ISO 3166-1 alpha-3 code |
name | string | Short name |
name_long | string | Long name |
iso_a3 | string | ISO 3166-1 alpha-3; -99 where Natural Earth assigns none |
iso_a2 | string | ISO 3166-1 alpha-2; -99 where Natural Earth assigns none |
continent | string | Continent |
subregion | string | UN subregion |
pop_est | number | Population estimate (persons) |
pop_year | integer | Year of the estimate |
gdp_md | number | GDP, millions of US dollars (USD m) |
gdp_year | integer | Year of the GDP figure |
economy | string | Natural Earth economy class |
income_group | string | World Bank income group |
/data/indicators.geojson — EPSG:4326; the geometry is in geometry (Point).
| column | type | meaning |
|---|---|---|
iso_a3 | string | Natural Earth ISO3 country key |
country | string | Natural Earth country name |
co2_pc_2010 | number | CO2 emissions excluding LULUCF per capita in 2010; null where unavailable (t CO2e/person) |
co2_pc_2022 | number | CO2 emissions excluding LULUCF per capita in 2022; null where unavailable (t CO2e/person) |
These are where the teaching is. Read them twice.
The World Bank WDI indicator EN.GHG.CO2.PC.CE.AR5 is sourced from EDGAR/JRC and excludes LULUCF (https://api.worldbank.org/v2/indicator/EN.GHG.CO2.PC.CE.AR5?format=json). World Bank terms describe reuse and attribution (https://data.worldbank.org/summary-terms-of-use).
Files: /data/countries.geojson, /data/indicators.geojson · assign result
7 scored, 0 informational
Countries with comparable year pairs
20%Correct set of comparable countries
20%Retains original and mapped values
13%Countries with a positive true change
13%Largest true decrease is retained
13%Diverging display field has its declared lower cap
13%Maps country polygons
7%