#!/bin/bash # Reproduce every table and figure of WP42 from the validated datasets (no API call), then compile the manuscript. set -e; cd "$(dirname "$0")/.."; export PYTHONPATH=src; PY=.venv/bin/python $PY -m pytest -q tests for t in pilot sensitivity recovery; do $PY -m wp42.cli export --tag $t; done $PY analysis/econometrics/estimate.py --tag pilot --B 5000 --perm 20000 > logs/estimate_pilot.txt $PY analysis/figures/fig01_architecture.py; $PY analysis/figures/fig02_benchmark_coverage.py $PY analysis/figures/make_figures.py --tag pilot $PY analysis/robustness/audit_pilot.py --tag pilot > logs/audit_pilot.txt $PY analysis/robustness/sensitivity_models.py > logs/sensitivity.txt $PY analysis/robustness/recovery_experiment.py > logs/recovery.txt $PY analysis/robustness/economic_sensitivity.py > logs/economic.txt $PY analysis/robustness/extra_descriptives.py > logs/extra.txt $PY protocol/power_analysis/power_simulation.py --out analysis/tables/power_pilot.csv > /dev/null $PY scripts/build_registry.py > /dev/null $PY -m wp42.dashboard --out dashboard/index.html cp analysis/figures/out/fig01_architecture.pdf manuscript/figures/ (cd manuscript && latexmk -pdf -interaction=nonstopmode main.tex > /dev/null && pdfinfo main.pdf | grep Pages) echo "reproduce_all: done"