Skip to content
Back to skills

Regression Table

ASecurity

Formats estimation output as a publication-quality regression table with stars, SEs, and fit statistics. Use when creating a results table.

  • 5,142 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added September 3, 2026
researchpythonbash

Security analysis

A100/100

Scanned September 3, 2026

npx -y skills add brycewang-stanford/Auto-Empirical-Research-Skills --skill regression-table --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Regression Table?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Regression Table
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/brycewang-stanford-regression-table/badge)](https://www.skillsdirectory.com/skills/brycewang-stanford-regression-table)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: regression-table
description: Formats estimation output as a publication-quality regression table with stars, SEs, and fit statistics. Use when creating a results table.
argument-hint: <notebook> [description]
allowed-tools: Bash, Read, Write, Edit, Glob, Grep
---

# Format Regression Table

Create a publication-quality regression table from estimation output in a notebook.

## Arguments

- `$ARGUMENTS` — a notebook reference and/or description of the table (e.g., "notebook-02 OLS results" or "main regression table with 3 specifications")

## Steps

1. Identify the source notebook and the estimation output:
   - If a notebook name is provided, read that notebook
   - If no notebook is specified, ask the user which notebook contains the regression results
   - Look for cells with estimation commands (Python: `statsmodels`, `linearmodels`; R: `lm`, `fixest`, `felm`; Stata: `reg`, `reghdfe`, `ivregress`)

2. Ask the user for table specifications:
   - Which models/columns to include
   - Dependent variable name(s)
   - Which coefficients to display (or "all")
   - Fixed effects to report as Yes/No rows
   - Clustering level for standard errors
   - Any custom notes for the table footer

3. Construct the table following academic conventions:
   - **Header row:** Dependent variable name spanning all columns, column numbers (1), (2), (3)...
   - **Coefficient rows:** Point estimate on top, standard error in parentheses below
   - **Significance stars:** `*` p<0.10, `**` p<0.05, `***` p<0.01
   - **Fixed effects rows:** Yes/No indicators
   - **Summary rows:** Observations (N), R-squared, Adjusted R-squared, or other fit statistics
   - **Footer:** Significance legend and notes about standard errors

4. Create or update a cell in the specified notebook with:
   - Cell directive: `#| label: tbl-<descriptive-name>` (or `*|` for Stata)
   - Cell directive: `#| tbl-cap: "<caption>"` (or `*|` for Stata)
   - The code to generate the formatted Markdown table
   - **Stata caveat:** Do NOT use `tbl-` prefix for Stata text output — use a plain label instead (e.g., `stata-regression`)

5. Sync the Jupytext pair:
   ```bash
   uv run jupytext --sync notebooks/<name>.md
   ```

6. Show the user the embed shortcode to paste into `index.qmd`:
   ```
   {{< embed notebooks/<name>.ipynb#tbl-<label> >}}
   ```

## Error handling

- If the notebook has no estimation output, report this and ask the user to run the regressions first.
- If the estimation output format is not recognized, ask the user to provide the raw coefficients and standard errors.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in research →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.