/superRA:econ-data-analysisfrom superRA
Imports, cleans, merges, filters, aggregates, and runs summary stats, regressions, and figures on economic, financial, or panel data. Enforces describe-before-transform discipline.
Ships in superRA. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Load per stage, not all at once:
| Reference | Load when |
|---|---|
references/planning.md | PLAN phase — data inventory and sensitivity analysis design. |
references/data-robustness-checklist.md | PLAN (design) and IMPLEMENT (execution of sensitivity tasks) — menu of robustness checks. |
references/integrate-drift-tests.md | protection stage — data-analysis key-result identification, econ-specific tolerances, data-analysis failure modes for drift/regression tests. |
references/integration.md | INTEGRATE stage — data-specific refactor-integrity gates. |
references/notebook-format.md | IMPLEMENT stage (for implementer) — cell organization, narrative, output idioms, Python jupytext / Julia Quarto rendering. Companions: jupytext-guide.md, julia-quarto-guide.md. |
NO TRANSFORMATION WITHOUT PRIOR DESCRIPTION
Transformed without describing first? Undo it and describe fresh from the current data state — not from a previous session, not "later at the end."
Concurrent, not sequential — every analysis step exercises all three, with documentation alongside.
Shared checklist: implementer before DONE, reviewer within its focus. These items apply to every analysis task; operation-conditional items live in §Pitfalls.
[BLOCKING] — must fix to earn APPROVE.[ADVISORY] — recorded; never blocks APPROVE.Committed diagnostics, row-count logs, and output files are the evidence. A missing diagnostic is a finding, not a prompt to generate it yourself. When fixing, re-run the changed step and its downstream dependents; unaffected upstream outputs stand as committed.
Describe before and after every transformation. The post-transformation describe feeds Sanity checks below.
After loading any dataset:
[BLOCKING] Every input described before the first transformation on it.[BLOCKING] Panel structure — first priority for panel/longitudinal data, the common case. Pure cross-section: note it, skip these.
[BLOCKING] Variable diagnostics on key variables — do NOT blanket-describe() all columns:
[BLOCKING] Data types and missing values:
Data already imported and validated upstream: read the existing diagnostics instead of re-running full validation.
Outlier flagging:
[BLOCKING] Observations beyond p1/p99 flagged and assessed.
[ADVISORY] If winsorizing, cutoff documented; robustness with alternatives considered (see references/data-robustness-checklist.md).After every major transformation (re-describe):
[BLOCKING] Descriptive statistics re-run on affected variables, compared against pre-transformation values.
Visualization for key variables — plot what summary statistics hide:
[BLOCKING] A companion figure wherever visualization is feasible, which covers most analyses. A key variable carried through the analysis without one is a finding.
[ADVISORY] Visualization not feasible — a lone scalar, too many series to plot individually, a figure that would not clarify: say which and move on.Transform data with integrity. Operation-specific traps: §Pitfalls.
[BLOCKING] One logical operation per step. One verb per step — merge, filter, construct, aggregate, reshape, deduplicate. No chaining merge + filter + construct.[BLOCKING] Row-count logging at every sample-changing operation. Print before → after for every merge, filter, drop, deduplication, or sample restriction.
Numbers must make economic sense — checked against priors, literature, cross-variable relationships, and alternative specifications. Runs on the output of every Analyze step, not at the end.
Sanity checks (after every Analyze step; minimum bar before proceeding):
[BLOCKING] Row count matches a stated expectation, not just logged.
[BLOCKING] Economic sense.
[BLOCKING] Task objective expectations comparison. Task objective states Expected Results or Hypotheses: compare findings explicitly, flag divergences before moving on.Anything unexpected: STOP and investigate.
Multi-source validation (key variables and headline numbers):
[BLOCKING] Every key variable and headline number checked against at least one external reference, for scale, sign, and relationship.
Missing-data as signal (interrogate before handling — how-to in §Pitfalls §Missing data handling):
[BLOCKING] Systematic missingness (concentrated in time, geography, or correlated with other variables) investigated — true absence vs construction error.[BLOCKING] "Missing" meaning disambiguated. No position (→ zero) vs didn't report (→ truly missing). Missing returns treated as zero is almost always wrong.Sensitivity analysis (design in references/planning.md; menu in references/data-robustness-checklist.md):
[ADVISORY] Sensitivity checks run on robustness-sensitive tasks, one alternative specification at a time — sample cutoff, variable definition, winsorization, leave-one-out.
[BLOCKING] Divergence escalated. A sensitivity check with a meaningfully different result: STOP and AskUserQuestion.
[BLOCKING] Analysis scripts follow the notebook-compatible format per references/notebook-format.md.[BLOCKING] Major decisions (filter threshold, join type, variable definition, sample period) carry a markdown-cell justification; minor decisions carry an inline comment.[BLOCKING] Outputs (tables, figures) are generated from committed code, not ad-hoc REPL state.[BLOCKING] In a superRA task, task-specific result-producing code follows using-superra/references/task-companion-files.md.[BLOCKING] Markdown cells explain what each block does and why.[BLOCKING] Headline findings presented visually. Each headline result as a figure — a distribution, a relationship, or a time path.
[BLOCKING] Figures saved under the task's attachments/ directory and embedded in task ## Results as attachments/fig.png per superRA:communicate.integration stage — references/integration.md (codebase consistency, data discipline preserved through refactoring, utility reuse, documented deviations).superimplement/references/completion.md §Verify the Work.Operation-conditional — walk a subsection only when the task performs that operation. Severity markers match the main checklist.
[BLOCKING] Before — describe both sides. Row counts and unique join-key values in both tables; key overlap and type compatibility.
[BLOCKING] Join type declared. Decide 1:1, m:1, or 1:m before writing the merge; confirm the post-merge row count against it.
[BLOCKING] Unmatched rows logged. How many rows from each side did not match; whether non-matching is random or systematic.[BLOCKING] Sort first. By panel ID + time, before any lag, lead, diff, or cumsum. Joins destroy sort order — re-sort after every merge.[BLOCKING] Check for gaps before lags/leads/diffs.
i is missing period t, a naive shift(1) treats period t+1's lag as t-1's value — silently wrong.[BLOCKING] Use time-aware operators when available.
PanelShift.jl handles gaps.reindex to a full time grid before shifting.[BLOCKING] After pivot: unique IDs × unique time periods should match original shape.[BLOCKING] Check for unintended NAs from unbalanced panels going wide.[BLOCKING] Function matches content. Sum dollar amounts, average rates — never the reverse.[BLOCKING] Group-by keys match intended level (country-year, not country-month).[BLOCKING] Weights verified. Weighted average: weights sum to expected values.[BLOCKING] Duplicates handled before aggregating — dupes cause double-counting.[BLOCKING] Uniqueness checked before operations that assume it (merges, index-setting).[BLOCKING] Which duplicate kept, and why (first, last, highest value).[BLOCKING] Rows dropped logged — count, reason, before/after.[BLOCKING] Non-randomness of drops checked. Drops concentrated in certain countries, periods, or variable ranges are sample-selection-bias risk.[BLOCKING] Boolean logic verified. & vs | is a common silent bug; chained filters compound.[BLOCKING] Transformation order: log → winsorize → standardize. Log after standardize fails on negative standardized values.[BLOCKING] Ratio denominators checked for zero/near-zero; extreme ratios often come from small denominators.[BLOCKING] Growth rates: spot-checked against published benchmarks; first differences amplify measurement error — inspect for implausible spikes.[BLOCKING] Standardization: mean ≈ 0, std ≈ 1 within the relevant sample; cross-sectional vs time-series vs pooled stated.Handling missingness (for interpretation, §Validate §Missing-data as signal):
[BLOCKING] Handling is visible and auditable — .fillna(0), .dropna(), and filters explicit; package defaults that silently ignore NaN in aggregations checked against the analytical objective.[BLOCKING] Prefer passing missing through the pipeline over filling silently; fill or coalesce only with explicit justification.Excuses that precede Iron Law violations. Catch yourself forming one: undo the transformation and describe first.
| Excuse | Reality |
|---|---|
| "Already know this data" / "Same as last session" | Your memory ≠ current state. Files and upstream code change. Describe fresh. |
| "Just a simple merge, I can skip the describe" | Simple merges create the worst silent bugs. |
| "Quick exploration, not formal analysis" | If results inform a decision, they need validation. |
| "I'll validate at the end" | Can't isolate which step caused the problem. |
| "Only filtering, not transforming" | Filters change your sample. Log what you're losing. |
references/data-robustness-checklist.md (opens in a new tab)references/integrate-drift-tests.md (opens in a new tab)references/integration.md (opens in a new tab)references/julia-quarto-guide.md (opens in a new tab)references/jupytext-guide.md (opens in a new tab)references/notebook-format.md (opens in a new tab)references/planning.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
panel-data, econometrics, data-cleaning, regression, data-validation
22 skills in this plugin
/academic-writingUse by default for .tex sources. In other formats, use for publication-quality writing such as manuscripts, exhibit notes, footnotes, appendices, and response letters. Covers proofreading, polishing, drafting, reviewing, and citation or consistency checks./agent-orchestrationCoordinate superRA agents and handoffs. Requires superRA:using-superra. Use to dispatch roles, run parallel agents, choose reviewers, or preserve workflow state./communicateCommunication discipline for writing, rewriting, distilling, and reviewing any text meant for human reading, including conversation, task files, planning updates, results, reports, reviews, handoffs, documentation, and interactive HTML pages. Use for every message or artifact a human will read; Must load for superRA who produces human-facing text./handoff-docDEPRECATED. Redirects to task-tree and the role skills./implement-taskImplementer role protocol for a superRA task — execute the objective, self-check, write results into the task file, commit, and return status. Load when a dispatch assigns you an implementer seat or when you fill one yourself./mistral-pdf-to-markdownConvert PDFs to Markdown with Mistral OCR and extracted images. Use for scanned PDFs or complex layouts where structured text or images matter.npx claudepluginhub fuzhiyu/superra --plugin superRAOther plugins' skills for the same job