Agent skill · Audited from source
r-econometrics
skill · meleantonio/awesome-econ-ai-stuffNOASSERTION licenceAudited 21 Oct 2026 · source 369fe15b2a25
Is it safe? Yes — SAFE, grade B (89/100). We read this skill's source at commit 369fe15b2a25 and found no filesystem, network or shell access and no hard-coded secrets. What it does: Run IV, DiD, and RDD analyses in R with proper diagnostics
Cite
Cite this page
ModelsAtlas. “r-econometrics (meleantonio/awesome-econ-ai-stuff)”. Retrieved 21 Oct 2026. https://modelsatlas.com/skills/meleantonio/r-econometrics
Trust audit
Audit 0.4.1 · source read 21 Oct 2026
SAFE means nothing in the source contradicts what the skill says it does. Grade B is shared by 16,667 of 17,602 audited skills.
What the source does
- FilesystemNone observedNo reads or writes in the source
- NetworkNone observedNo outbound calls in the source
- ShellNone observedNo commands run in the source
- DependenciesPinnedNothing floats
- SecretsNone foundNo keys in source
Five audit layers
| Layer | What we check | Result | Findings |
|---|---|---|---|
L0 Provenance | Repo owner, licence, archive status, activity | PASS | 0 |
L1 Static source | Secrets, path traversal, supply chain, hidden code | NA | 0 |
L2 Instructions | Prompt injection, authority framing, hidden directives | PASS | 0 |
L3 Inventory | The files and declarations match the source | PASS | 0 |
L4 Sandbox | Run in isolation and watch behaviour | SKIPPED why | 0 |
Gates applied: no behavioural pass.
Findings (0)
No findings at any severity. We re-audit when the source changes.
Audit 0.4.1 · source sha 369fe15b2a25 · 21 Oct 2026Report an issue or request a re-scan
Provenance
Who published it, and what the verdict is pinned to
- Publishermeleantonio GitHub userOwner of the repository this skill is read from
- Source foldermeleantonio/awesome-econ-ai-stuff/_skills/analysis/r-econometricsThe exact folder we audited
- LicenceNOASSERTIONAs the repository states it
- Commit pinned for this verdict369fe15b2a25A new audit runs when the source changes
- Repository statusNot archivedLast push 25 days ago
- Sandboxed runNot runSkills are read, not executed; layer L4 is skipped
What it tells the agent
Full source on GitHub ↗Its description: Run IV, DiD, and RDD analyses in R with proper diagnostics
---
name: r-econometrics
description: Run IV, DiD, and RDD analyses in R with proper diagnostics
workflow_stage: analysis
compatibility:
- claude-code
- cursor
- codex
- gemini-cli
author: Awesome Econ AI Community
version: 1.0.0
tags:
- R
- econometrics
- causal-inference
- fixest
- regression
---
# R Econometrics
## Purpose
This skill helps economists run rigorous econometric analyses in R, including Instrumental Variables (IV), Difference-in-Differences (DiD), and Regression Discontinuity Design (RDD). It generates publication-ready code with proper diagnostics and robust standard errors.
## When to Use
- Running causal inference analyses
- Estimating treatment effects with panel data
- Creating publication-ready regression tables
- Implementing modern econometric methods (two-way fixed effects, event studies)
## Instructions
### Step 1: Understand the Research Design
Before generating code, ask the user:
1. What is your identification strategy? (IV, DiD, RDD, or simple regression)
2. What is the unit of observation? (individual, firm, country-year, etc.)
3. What fixed effects do you need? (entity, time, two-way)
4. How should standard errors be clustered?
### Step 2: Generate Analysis Code
Based on the research design, generate R code that:
1. **Uses the `fixest` package** - Modern, fast, and feature-rich for panel data
2. **Includes proper diagnostics:**
- For IV: First-stage F-statistics, weak instrument tests
- For DiD: Parallel trends visualization, event study plots
- For RDD: Bandwidth selection, density tests
3. **Uses robust/clustered standard errors** appropriate for the data structure
4. **Creates publication-ready output** using `modelsummary` or `etable`
### Step 3: Structure the Output
Always include:
```r
# 1. Setup and packages
# 2. Data loading and preparation
# 3. Descriptive statistics
# 4. Main specification
# 5. Robustness checks
# 6. Visualization
# 7. Export results
```
### Step 4: Add Documentation
Include comments explaining:
- Why each specification choice was made
- Interpretation of key coefficients
- Limitations and assumptions
## Example Prompts
- "Run a DiD analysis with state and year fixed effects, clustering at the state level"
- "Estimate the effect of X on Y using Z as an instrument"
- "Create an event study plot showing treatment effects by year"
- "Run a sharp RDD with optimal bandwidth selection"
## Example Output
```r
# ============================================
# Difference-in-Differences Analysis
# ============================================
# Setup
library(tidyverse)
library(fixest)
library(modelsummary)
# Load data
df <- read_csv("data.csv")
# Prepare treatment variable
df <- df %>%
mutate(
post = year >= treatment_year,
treated = state %in% treatment_states,
treat_post = treated * post
)
# ----------------------------------------
# Main DiD Specification
# ----------------------------------------
# Two-way fixed effects
did_model <- feols(
outcome ~ treat_post | state + year,
data = df,
cluster = ~state
)
# View results
summary(did_model)
# ----------------------------------------
# Event Study
# ----------------------------------------
# Create relative time variable
df <- df %>%
mutate(rel_time = year - treatment_year)
# Event study regression
event_study <- feols(
outcome ~ i(rel_time, treated, ref = -1) | state + year,
data = df,
cluster = ~state
)
# Plot coefficients
iplot(event_study,
main = "Event Study: Effect on Outcome",
xlab = "Years Relative to Treatment")
# ----------------------------------------
# Robustness: Alternative Specifications
# ----------------------------------------
# Different clustering
did_robust <- feols(
outcome ~ treat_post | state + year,
data = df,
cluster = ~state + year # Two-way clustering
)
# ----------------------------------------
# Export Results
# ----------------------------------------
modelsummary(
list("Main" = did_model, "Two-way Cluster" = did_robust),
stars = c('*' = 0.1, '**' = 0.05, '***' = 0.01),
output = "results/did_table.tex"
)
```
## Requirements
### Software
- R 4.0+
### Packages
- `fixest` - Fast fixed effects estimation
- `modelsummary` - Publication-ready tables
- `tidyverse` - Data manipulation
- `ggplot2` - Visualization
Install with:
```r
install.packages(c("fixest", "modelsummary", "tidyverse"))
```
## Best Practices
1. **Always cluster standard errors** at the level of treatment assignment
2. **Run pre-trend tests** for DiD designs
3. **Report first-stage F-statistics** for IV (should be > 10)
4. **Use `feols` over `lm`** for panel data (faster and more features)
5. **Document all specification choices** in your code comments
## Common Pitfalls
- ❌ Not clustering standard errors at the right level
- ❌ Ignoring weak instruments in IV estimation
- ❌ Using TWFE with staggered treatment timing (use `did` or `sunab()` instead)
- ❌ Not reporting robustness checks
## References
- [fixest documentation](https://lrberge.github.io/fixest/)
- [Cunningham (2021) Causal Inference: The Mixtape](https://mixtape.scunning.com/)
- [Angrist & Pischke (2009) Mostly Harmless Econometrics](https://www.mostlyharmlesseconometrics.com/)
## Changelog
### v1.0.0
- Initial release with IV, DiD, RDD supportExcerpt, first 5,318 characters of SKILL.md, verbatim from the audited commit. It is text from someone else’s repository, quoted so you can judge it before your agent reads it.
Install
Pinned to the audited commit 369fe15
git clone https://github.com/meleantonio/awesome-econ-ai-stuff git -C awesome-econ-ai-stuff checkout 369fe15b2a25
The author documents no install command, so this uses the repository directly. Our verdict covers commit 369fe15b2a25 only.
Works in which agents?
What its own text says, not a test
| Agent | Status | More |
|---|---|---|
| Codex | Mentioned in its text, not tested | Skills for Codex · About Codex |
| Cursor | Mentioned in its text, not tested | Skills for Cursor · About Cursor |
Audit history
Every audit, every source change
- ✓SAFE B 89 / 100
first audit · source
369fe15b2a25
README badge
For maintainers · shows the latest audit
[](https://modelsatlas.com/skills/meleantonio/r-econometrics/)
The badge shows our verdict and grade for this skill, and links back to this page. It changes when the audit does.
Similar skills
obra/superpowers
Use when creating new skills, editing existing skills, or verifying skills work before deployment
mattpocock/skills
A relentless interview to sharpen a plan or design, which also creates docs (ADR's and glossary) as we go.
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.
Add this badge to your README
[](https://modelsatlas.com/skills/meleantonio/r-econometrics/)
<a href="https://modelsatlas.com/skills/meleantonio/r-econometrics/"><img src="https://modelsatlas.com/skills/meleantonio/r-econometrics/badge.svg" alt="ModelsAtlas: SAFE B"></a>
Questions about r-econometrics
What does the r-econometrics skill do?
Is r-econometrics safe to install?
What can r-econometrics access on my machine?
Which assistants does r-econometrics work with?
How current is this page?
Sources
- github.com/meleantonio/awesome-econ-ai-stuff/tree/main/_skills/a — the audited source at commit 369fe15b2a25 and every finding aboveObserved · 21 Oct 2026
Spotted something wrong? Report a correction · Methodology
Keep going in your AI
Opens with this page as the source. We add nothing else to the prompt.
- What does the r-econometrics skill do?
- Is r-econometrics safe to install?
- What can r-econometrics access on my machine?