causal-inference

Implement causal identification strategies like IV/2SLS, DiD, RDD, synthetic control, and matching.

11|2|Updated Feb 26, 2026
One-click install
npx skills add https://github.com/James-Traina/compound-science --skill causal-inference-james-traina
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: causal-inference
Source: https://github.com/James-Traina/compound-science/tree/main/skills/causal-inference
Command: npx skills add https://github.com/James-Traina/compound-science --skill causal-inference-james-traina

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps researchers identify causal effects from observational data by outlining methodological frameworks, identification arguments, and estimation strategies across common quasi-experimental designs.

Core Features & Use Cases

  • Identification strategies: IV/2SLS, DiD, RDD, synthetic control, and matching.
  • Diagnostics & robustness: Pre-trends checks, overidentification tests, and sensitivity analyses.
  • Use Case: A policy evaluator uses DiD with staggered adoption to estimate treatment effects while checking for parallel trends and robustness.

Quick Start

Provide a causal research question and data, then choose an identification strategy (IV/2SLS, DiD, or RDD) and run diagnostics.

Frequently Asked Questions about causal-inference

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I estimate treatment effects using difference-in-differences with staggered adoption?

To estimate treatment effects with difference-in-differences (DiD) under staggered adoption, you implement the design using observational data while checking for parallel pre-trends and running robustness diagnostics. The framework provides practical examples and code snippets for this exact quasi-experimental setup.

What is the best way to identify causal effects from observational data?

Identifying causal effects from observational data requires outlining methodological frameworks and identification arguments. You choose from strategies like IV/2SLS, DiD, RDD, synthetic control, or matching, then apply diagnostics and robustness checks to support reproducible analysis.

Can I run causal inference diagnostics like overidentification tests in Python and R?

Yes, you can run causal inference diagnostics such as overidentification and pre-trends tests in both Python and R. The framework provides practical guidance with definitions, examples, and code snippets across both languages to support reproducible analysis.

When do I need to use synthetic control versus regression discontinuity design?

You need synthetic control when estimating treatment effects for a single treated unit by creating a weighted synthetic counterfactual, whereas regression discontinuity design (RDD) is used when treatment assignment is determined by a threshold cutoff. Both are supported quasi-experimental identification strategies.

How do I set up an instrumental variables 2SLS estimation strategy?

To set up an instrumental variables (IV/2SLS) estimation strategy, you provide a causal research question and observational data, select IV/2SLS as your identification approach, and run overidentification tests to ensure instrument validity within your reproducible analysis workflow.