Full-empirical-analysis-skill
Classical end-to-end empirical analysis workflow in the traditional Python econometric stack — pandas + numpy + scipy + statsmodels + linearmodels + pyfixest + rdrobust + econml + causalml + matplotlib/seaborn. **Defaults to economics empirical-paper style** (AER / QJE / AEJ) — every run produces a publication-ready output set with a multi-column regression table (M1→M6 progressive controls/FE) as the centerpiece, plus Table 1 (descriptives), mechanism / heterogeneity / robustness tables, and event-study + coefficient + trend figures. Covers the full 8-step pipeline an applied economist or qua
npx skills add brycewang-stanford/Auto-Empirical-Research-Skills --skill 00.1-Full-empirical-analysis-skill_Python --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
What it does
Provides an end-to-end empirical analysis pipeline in Python for economics papers. It guides data cleaning, variable construction, descriptive statistics (Table 1), diagnostic tests, baseline modeling, robustness checks, mechanism/heterogeneity analyses, and produces publication-ready outputs including a multi-column regression table (Table 2) and associated figures (F1–F4). The outputs are organized into tables/ and figures/ with explicit formats and file paths. The centerpiece is a six-spec regression table (M1→M6) created via pyfixest.feols and exported through pf.etable or Stargazer, accompanied by descriptive tables, heterogeneity analyses, robustness variants, mechanism tables, and a suite of visuals (trend, event-study, coefficient plot, and sensitivity curves). It enforces that images are exported in PNG (≥300 dpi) and PDFs, and that tables are exported in Excel (.xlsx), Word (.docx), and LaTeX (.tex). It supports a default economics mode and two alternate domains (Mode A epidemiology/public health and Mode B ML causal inference), switching estimators and reporting stacks accordingly. It can respond to a wide range of triggers, including requests for specific steps (e.g., Table 1, event study, IV, RD, DID, etc.) or mode changes, while preserving the same core 1–4 cleaning/descriptives/diagnostics scaffold and Step 8 export format.
How it works
- Cleans data and constructs variables per the canonical 8 steps.
- Generates Table 1 via pandas.describe and a custom table1() for descriptives and balance.
- Runs regression specifications M1 through M6 using pyfixest.feols and aggregates results with pf.etable or Stargazer to produce Table 2.
- Produces Table 3 (mechanism/outcome ladder), Table 4 (heterogeneity), and Table 5 (robustness) by looping/stacking estimators and variants.
- Creates figures: F1 (trend over time), F2 (event-study with 95% CI), F3 (coefficient plot across specs), F4 (robustness/sensitivity curve).
- Exports all outputs in required formats: tables as Excel/Word/LaTeX; figures as PNG (≥300 dpi) and PDF. The project layout places tables under tables/ and figures under figures/ with specified filenames.
- Provides a Mode switch to Mode A (epidemiology/public health) or Mode B (ML causal inference), altering Step 5 estimator stacks and reporting stacks while keeping Step 1–4 scaffolding and Step 8 outputs consistent.
When to use it
Use when you need a complete empirical analysis pipeline in Python that mirrors traditional economics papers, with explicit control over each estimator and diagnostic, and with publication-ready outputs. It’s invoked for full empirical pipelines, or when a user asks for a full workflow or mentions components like Table 1, event study, or robustness checks.
What it can touch
Libraries and tooling explicitly named for estimators and diagnostics include: pandas, numpy, scipy, statsmodels, linearmodels, pyfixest, rdrobust, econml, causalml, matplotlib, seaborn. Outputs are written to standard folders: tables/ and figures/ with file formats as described.
Caveats
License is NOASSERTION. The skill emphasizes transparency and explicit library usage over wrapped defaults, and requires runnable blocks with pip install -r requirements.txt and data loading steps. It adheres to publication-ready formatting rules including multi-format exports and 300 dpi PNGs; no outcomes beyond those described are promised.
# Full Empirical Analysis — Classical Python Workflow This skill is the *canonical* 8-step pipeline an applied economist runs on every empirical paper, written in the **traditional Python ecosystem** — no opinionated one-stop wrapper. Every step calls libraries directly (`pandas`, `numpy`, `scipy`, `statsmodels`, `linearmodels`, `pyfixest`, `rdrobust`, `econml`, `causalml`, `matplotlib`, `seaborn`
What does the Full-empirical-analysis-skill skill do?
Classical end-to-end empirical analysis workflow in the traditional Python econometric stack — pandas + numpy + scipy + statsmodels + linearmodels + pyfixest + rdrobust + econml + causalml + matplotlib/seaborn. **Defaults to economics empirical-paper style** (AER / QJE / AEJ) — every run produces a publication-ready output set with a multi-column regression table (M1→M6 progressive controls/FE) as the centerpiece, plus Table 1 (descriptives), mechanism / heterogeneity / robustness tables, and event-study + coefficient + trend figures. Covers the full 8-step pipeline an applied economist or qua
How do I install it?
Run `npx skills add brycewang-stanford/Auto-Empirical-Research-Skills --skill 00.1-Full-empirical-analysis-skill_Python --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From brycewang-stanford/Auto-Empirical-Research-Skills, a repository with 3,244 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.