SPB Git

spb/wp29_uqo

Public
4.2 KB · 43 lines markdown
1# F1-conf-02 — Balanced-panel mean life expectancy, 2000–202223## Scientific question4Measure the change in life expectancy at birth between 2000 and 2022 across a fixed set of countries. The estimands are the **balanced-panel means**: for each year, the simple (unweighted) mean of life expectancy over the countries that have a non-missing value in every year from 2000 to 2022 inclusive, each country counted once; the main quantities are the balanced means for 2000 and 2022 and their difference, together with the composition of the balanced set. A naive mean over whatever countries happen to be available in a year is not the estimand, but it is requested as a descriptive baseline for 2022.56## Inputs7- `data/life_expectancy_panel.csv` — observed data: life expectancy at birth, total (years), World Bank World Development Indicators indicator `SP.DYN.LE00.IN`, 20 countries, years 2000–2022. Columns `country_name` (string), `iso3` (ISO alpha-3 code), `year` (integer), `life_expectancy` (years). Source URL, retrieval date, license and SHA-256 are in `data/README.md`. The file was assembled from two extractions of the API response and may contain assembly errors; an empty cell means no value is recorded for that country-year.89## Information-availability rules10- Use only `data/life_expectancy_panel.csv`. Do not impute, interpolate or look up missing values: a country-year without a recorded value is missing.11- A country is identified by its `iso3` code; each country contributes at most one observation per year.1213## Required outputs14- `out/results.json` with the keys:1516| key | type | unit | meaning |17|---|---|---|---|18| `task_id` | string | — | "F1-conf-02" |19| `n_countries_total` | integer | countries | distinct countries (iso3) present in the file |20| `n_countries_balanced` | integer | countries | countries with a recorded value in every year 2000–2022 |21| `n_countries_incomplete` | integer | countries | distinct countries not in the balanced set |22| `balanced_countries` | array of strings | — | iso3 codes of the balanced set, sorted |23| `n_analysed` | integer | country-years | rows of the balanced analytic dataset (countries × years) |24| `mean_2000_balanced` | number | years | balanced-panel mean life expectancy in 2000 |25| `mean_2022_balanced` | number | years | balanced-panel mean life expectancy in 2022 |26| `change_2000_2022_balanced` | number | years | `mean_2022_balanced − mean_2000_balanced` |27| `mean_2022_all_available` | number | years | baseline: mean over all distinct countries with a recorded 2022 value, each counted once |28| `feasibility` | string | — | "complete", "partial" or "infeasible" |29| `feasibility_reason` | string or null | — | explanation if not complete |30| `data_issues` | array of {"issue","handling"} | — | every data problem detected and how it was handled (empty list if none) |31| `n_input_rows` | object | rows | {"life_expectancy_panel.csv": number of data rows read (excluding the header)} |32| `random_seed` | integer or null | — | seed used, if any |3334- `out/analytic.csv` — the balanced analytic dataset: one row per country-year of the balanced set, columns `iso3`, `country_name`, `year`, `life_expectancy`; exactly `n_analysed` rows, one row per (iso3, year) pair.35- `out/exclusions.csv` — the exclusion ledger with columns `step`, `rule`, `n_before`, `n_after`, `n_removed`, `rationale`; one row per step from the number of rows read to `n_analysed` (`n_before − n_removed = n_after` on every row; each step's `n_before` equals the previous step's `n_after`).36- `out/report.md` with the sections: Question; Data and exclusions; Method; Results; Uncertainty; Limitations and open issues.37- `out/analysis.py` — running `~/wp29/venv/bin/python out/analysis.py` from the workspace root must regenerate `out/results.json`, `out/analytic.csv` and `out/exclusions.csv` from `data/` only, deterministically.38- `out/claims.json` — a list of the central claims of the report: [{"id": "C1", "text": "...", "results_keys": ["..."], "status": "supported"|"unsupported"|"not_evaluated", "caveat": "..."}].3940## Constraints41- No network access. Python: `~/wp29/venv/bin/python` (numpy, pandas, scipy, statsmodels available). Do not modify `data/`.42- This task is designed to be completed in well under 15 minutes of work.43
Files · 449400ebf8aa08d286e9899c675eeb9b3997f6a3
Menu

Theme