data-analysis · lingzhi227 — Claude Code skill: stats analysis with 4-round review
Writes statistical analysis code for a paper: picks a test that fits the data and reports p-values, effect sizes and confidence intervals.
npx skills add lingzhi227/agent-research-skills --skill data-analysis -a claude-codeWhat data-analysis does
The skill takes a data source (CSV, JSON, pickle or experiment logs) plus the hypothesis you want to check. It then lays out an analysis script in sections: imports, loading the data, dataset preparation, descriptive statistics, preprocessing, the tests themselves, and saving extra results to pickle.
That code goes through four review rounds. The first hunts for mistakes in the maths and statistics. The second looks at data handling: missing values, units, exclusion criteria. Rounds three and four check tables for plausible values, uncertainty measures, and consistency across the whole report. A test-selection table ships inside the skill: t-test and Mann-Whitney for two groups, ANOVA and Kruskal-Wallis for several, chi-square and Fisher's exact for categorical data, plus correlation and regression.
Two helper scripts come along. stat_summary.py detects data types, suggests a test, runs comparisons and returns effect sizes with significance stars; it needs numpy and scipy. The other, format_pvalue.py, renders p-values as stars, LaTeX or plain text and uses only the standard library. Analysis is limited to pandas, numpy, scipy, statsmodels, sklearn and pickle, so a different stack is out of scope.
What it helps with
- pick a statistical test that matches the data type and group count
- attach a confidence interval or p-value to every reported estimate
- handle missing values, units and exclusion rules before tests run
- check that values and uncertainty measures agree across tables
- convert p-values into stars or LaTeX for typesetting
Example prompts for the agent
- Analyse
results.csv, compare methods on accuracy and report effect sizes - Test the group difference in
experiment.jsonand write up a report with confidence intervals - Format the pvalue column of
results.csvas LaTeX
How to install data-analysis
1Skills CLI (Vercel)
npx skills add lingzhi227/agent-research-skills --skill data-analysis -a claude-code2Manually: put the files in place
~/.claude/skills/data-analysis/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/data-analysis/
1Skills CLI (Vercel)
npx skills add lingzhi227/agent-research-skills --skill data-analysis -a codex2Manually: put the files in place
.agents/skills/data-analysis/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add lingzhi227/agent-research-skills --skill data-analysis -a cursor2Manually: put the files in place
.cursor/skills/data-analysis/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install lingzhi227/agent-research-skills data-analysis2Manually: put the files in place
.github/skills/data-analysis/SKILL.md1Skills CLI (Vercel)
npx skills add lingzhi227/agent-research-skills --skill data-analysis -a gemini-cli2Platform CLI
gemini skills install https://github.com/lingzhi227/agent-research-skills --path skills/data-analysisManually: put the files in place
.devin/skills/data-analysis/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add lingzhi227/agent-research-skills --skill data-analysis -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about data-analysis
How to install data-analysis in Claude Code?
Run npx skills add lingzhi227/agent-research-skills --skill data-analysis -a claude-code; the skill lands at ~/.claude/skills/data-analysis/SKILL.md.
What does data-analysis do?
It generates statistical analysis code for a hypothesis, sends it through four review rounds, and produces a report with p-values, effect sizes and confidence intervals.
Which packages does the skill require?
The allowed set is pandas, numpy, scipy, statsmodels, sklearn and pickle. stat_summary.py needs numpy and scipy, while format_pvalue.py relies on the standard library.
Similar skills
All skills for Science and research →data-analysis by other authors comes first.