Agent skill · AI & Agents

mcmc-sampling-stan

Guide for performing Markov Chain Monte Carlo (MCMC) sampling using RStan or PyStan. This skill should be used when implementing Bayesian statistical models, fitting hierarchical models, working with Stan modeling language, or running MCMC diagnostics. Applies to tasks involving posterior sampling, Bayesian inference, and probabilistic programming with Stan.

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill mcmc-sampling-stan --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 8 KB
Bundled scripts: none
Path: skills/ai-ml/mcmc-sampling-stan/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# MCMC Sampling with Stan ## Overview This skill provides guidance for implementing Bayesian models and running MCMC sampling using Stan (via RStan or PyStan). It covers model specification, prior implementation, sampling configuration, and critical diagnostic checks that must be performed to validate results. ## Workflow ### Phase 1: Environment Setup Before writing any Stan code: 1. **Verify Stan installation and version** - Check that the required version of RStan/PyStan is installed - RStan requires a C++ toolchain; verify compilation works before proceeding - For RStan: Check with `packageVersion("rstan")` and test compilation with a simple model 2. **Check system dependencies first** - Stan requires compilation; missing system libraries cause cryptic errors - On Linux: Ensure `g++`, `make`, and development libraries are installed - On macOS: Xcode command line tools required - Verify the toolchain before attempting package installation 3. **Common installation pitfalls** - R's `install.packages()` does not accept a `version` parameter for CRAN packages - To install a specific version, use `remotes::install_version()` or install from source - RStan compilation can fail silentl

What's inside
Steps it walks through
  1. Overview
  2. Workflow
  3. Phase 1: Environment Setup
  4. Phase 2: Data Exploration
  5. Phase 3: Model Implementation
  6. Phase 4: Sampling Configuration
  7. Phase 5: Diagnostic Checks (CRITICAL)
  8. Phase 6: Results Extraction
  9. Common Pitfalls
  10. Installation Issues
  11. Model Specification Errors
  12. Sampling Problems
  13. Diagnostic Omissions
  14. Output Errors
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the mcmc-sampling-stan skill do?

Guide for performing Markov Chain Monte Carlo (MCMC) sampling using RStan or PyStan. This skill should be used when implementing Bayesian statistical models, fitting hierarchical models, working with Stan modeling language, or running MCMC diagnostics. Applies to tasks involving posterior sampling, Bayesian inference, and probabilistic programming with Stan.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill mcmc-sampling-stan --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going