# Emcee Posterior Diagnostics

> Analyze posterior distributions, credible intervals, correlations, and diagnostic summaries from emcee chains.

- Skill: `rudrathegreat/emcee-posterior-diagnostics` (Agent Skill)
- Install (CLI): `npx skillmds@latest add rudrathegreat/emcee-posterior-diagnostics`
- Raw SKILL.md: https://api.skillmd.com/api/skills/rudrathegreat/emcee-posterior-diagnostics/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: rudrathegreat (https://skillmd.com/u/rudrathegreat)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/rudrathegreat/emcee-posterior-diagnostics

---


# Skill: emcee Posterior Diagnostician
## Category: Inference

### Purpose
Extract, calculate, and visualize posterior probability distributions and credible intervals from MCMC chain outputs.

### Capabilities
- Calculate median values and 68%, 95%, 99% credible intervals.
- Interpret corner/triangle plots for parameter degeneracies.
- Identify multi-modal distributions and construct covariance matrices.

### Limitations
- Relies on correctly formatted flat samples.
- Interpretation of physical degeneracies requires domain background.

### Recommended Workflows
1. Load flat chain samples.
2. Compute percentiles (16th, 50th, 84th).
3. Generate corner plots and write parameter summaries.

### Example Interactions
User: Extract the parameter values from my MCMC chains.
Agent: Computing percentiles: Parameter 1: 5.42 (+0.12, -0.15); Parameter 2: 12.34 (+1.02, -0.98). Generating corner plot script.

### Detailed System Prompt Content
```sysprompt
You are a data analysis scientist. Your task is to extract physical parameters from posterior chains. Always report parameter values in standard format: Value^{+upper}_{-lower} with appropriate units. Identify degeneracies (e.g. banana-shaped contours) and explain their physical meaning.
```

### Domain Expertise Guidance
Bayesian posterior extraction, corner library, statistical reporting standards.

### Recommended Tools and Libraries
corner, numpy, pandas.

### Common Failure Modes
Reporting mean and standard deviation for highly asymmetric or multi-modal distributions instead of quantiles.

### Realistic Astronomy Examples
Posterior result: Pulsar mass M_p = 1.44^{+0.03}_{-0.02} M_sun (68% CI).

