
stata-regression
Run regression analyses in Stata with publication-ready output tables.
- Installs
- 420
- Last 24h
- —
- Trending rank
- —
- Security
- Not audited
Install
Works with every agent the skills CLI supports.
npx skills add https://github.com/meleantonio/awesome-econ-ai-stuff --skill stata-regression- 01
Install
Run the command in your project. The CLI asks which agents to install for.
- 02
Describe the task
Ask your agent for something this skill covers. It loads stata-regression automatically when relevant.
- 03
Review the result
The agent follows the SKILL.md steps, scripts and references bundled with the skill.
SKILL.md
The instructions your agent reads when the skill is triggered.
Stata Regression
Purpose
This skill produces reproducible regression analysis workflows in Stata, including model diagnostics and publication-ready tables using esttab or outreg2.
When to Use
- Estimating linear or nonlinear regression models in Stata
- Producing tables for academic papers and reports
- Running robustness checks and alternative specifications
Instructions
Follow these steps to complete the task:
Step 1: Understand the Context
Before generating any code, ask the user:
- What is the dependent variable and key regressors?
- What controls and fixed effects are required?
- How should standard errors be clustered?
- What output format is needed (LaTeX, Word, or CSV)?
Step 2: Generate the Output
Based on the context, generate Stata code that:
- Loads and checks the data - Handle missing values and verify variable types
- Runs the requested specification - Use
regress,reghdfe, orxtregas appropriate - Adds robust or clustered standard errors - Match the study design
- Exports tables - Use
esttaboroutreg2with clear labels
Step 3: Verify and Explain
After generating output:
- Explain what each model estimates
- Highlight assumptions and diagnostics
- Suggest robustness checks or alternative models
Example Prompts
- "Run OLS with firm and year fixed effects, clustering by firm"
- "Estimate a logit model and export results to LaTeX"
- "Create a regression table with three specifications"
Example Output
* ============================================
* Regression Analysis with Stata
* ============================================
* Load data
use "data.dta", clear
* Summary stats
summarize y x1 x2 x3
* Main regression with clustered SEs
regress y x1 x2 x3, vce(cluster firm_id)
eststo model1
* Alternative specification with fixed effects
reghdfe y x1 x2 x3, absorb(firm_id year) vce(cluster firm_id)
eststo model2
* Export table
esttab model1 model2 using "results/regression_table.tex", replace se label
Requirements
Software
- Stata 17+
Packages
estout(foresttab)reghdfe(optional, for high-dimensional fixed effects)
Install with:
ssc install estout
ssc install reghdfe
Best Practices
- Match standard errors to the design (cluster where treatment varies)
- Report all model variants used in the analysis
- Document variable definitions and transformations
Common Pitfalls
- Not clustering standard errors at the correct level
- Omitting fixed effects when required by the design
- Exporting tables without clear labels and notes
References
Changelog
v1.0.0
- Initial release
FAQ
What does the stata-regression skill do?
Run regression analyses in Stata with publication-ready output tables.
How do I install stata-regression?
Run npx skills add https://github.com/meleantonio/awesome-econ-ai-stuff --skill stata-regression in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/stata-regression/ (personal) or .claude/skills/stata-regression/ (project).
Which AI agents can use stata-regression?
Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.
Is stata-regression safe to install?
No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.
Who maintains stata-regression?
It is published by meleantonio in meleantonio/awesome-econ-ai-stuff. It has 420 recorded installs.
More from meleantonio/awesome-econ-ai-stuff
academic-paper-writer
meleantonio/awesome-econ-ai-stuff
Draft economics papers with proper structure and academic style
stata-data-cleaning
meleantonio/awesome-econ-ai-stuff
Clean and transform messy data in Stata with reproducible workflows
r-econometrics
meleantonio/awesome-econ-ai-stuff
Open the skill to read its SKILL.md instructions.
beamer-presentation
meleantonio/awesome-econ-ai-stuff
Create academic presentations in Beamer with professional themes
lit-review-assistant
meleantonio/awesome-econ-ai-stuff
Open the skill to read its SKILL.md instructions.
api-data-fetcher
meleantonio/awesome-econ-ai-stuff
Open the skill to read its SKILL.md instructions.
Popular testing & qa skills
tdd
mattpocock/skills
Test-driven development. Use when the user wants to build features or fix bugs test-first, mentions "red-green-refactor", or wants integration tests.
grilling
mattpocock/skills
Grill the user relentlessly about a plan, decision, or idea. Use when the user wants to stress-test their thinking, or uses any 'grill' trigger phrases.
migrate-to-shoehorn
mattpocock/skills
Migrate test files from as type assertions to @total-typescript/shoehorn. Use when user mentions shoehorn, wants to replace as in tests, or needs partial test data.
run-train
lllllllama/rigorpilot-skills
Rigor Train skill for deep learning research repositories. Use when a documented or selected training command should be run conservatively for startup verification, short-run verification, full kickoff, or resume, with command, config, seed, log, checkpoint, status, and metric evidence written to standardized trainoutputs/. Do not use for environment setup, exploratory sweeps, speculative idea implementation, or end-to-end orchestration.
test-driven-development
obra/superpowers
Use when implementing any feature or bugfix, before writing implementation code
finishing-a-development-branch
obra/superpowers
Use when implementation is complete, all tests pass, and you need to decide how to integrate the work