Agent skill
running-placebo-analysis
Performs placebo-in-time sensitivity analysis to validate causal claims. Use when checking model robustness, verifying lack of pre-intervention effects, or ensuring observed effects are not spurious.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/data/running-placebo-analysis
SKILL.md
Running Placebo Analysis
Executes placebo-in-time sensitivity analysis to validate causal experiments.
Workflow
- Define Experiment Factory: Create a function that returns a fitted CausalPy experiment (e.g., ITS, DiD, SC) given a dataset and time boundaries.
- Configure Analysis: Initialize
PlaceboAnalysiswith the factory, dataset, intervention dates, and number of folds (cuts). - Run Analysis: Execute
.run()to fit models on pre-intervention data folds. - Evaluate Results: Compare placebo effects (which should be null) to the actual intervention effect. Use histograms and hierarchical models to quantify the "status quo" distribution.
Key Concepts
- Placebo-in-time: Simulating an intervention at a time when none occurred to check if the model falsely detects an effect.
- Fold: A slice of pre-intervention data used to test a placebo period.
- Factory Pattern: Decouples the placebo logic from the specific CausalPy experiment type.
References
- Placebo-in-time Implementation: Full code for the
PlaceboAnalysisclass, usage examples, and hierarchical status-quo modeling.
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?