rmcmc
0.1.2Robust Markov Chain Monte Carlo Methods
Overview
Functions for simulating Markov chains using the Barker proposal to compute Markov chain Monte Carlo (MCMC) estimates of expectations with respect to a target distribution on a real-valued vector space. The Barker proposal, described in Livingstone and Zanella (2022) doi:10.1111/rssb.12482, is a gradient-based MCMC algorithm inspired by the Barker accept-reject rule. It combines the robustness of simpler MCMC schemes, such as random-walk Metropolis, with the efficiency of gradient-based methods, such as the Metropolis adjusted Langevin algorithm. The key function provided by the package is sample_chain(), which allows sampling a Markov chain with a specified target distribution as its stationary distribution. The chain is sampled by generating proposals and accepting or rejecting them using a Metropolis-Hasting acceptance rule. During an initial warm-up stage, the parameters of the proposal distribution can be adapted, with adapters available to both: tune the scale of the proposals by coercing the average acceptance rate to a target value; tune the shape of the proposals to match covariance estimates under the target distribution. As well as the default Barker proposal, the package also provides implementations of alternative proposal distributions, such as (Gaussian) random walk and Langevin proposals. Optionally, if 'BridgeStan's R interface https://roualdes.us/bridgestan/latest/languages/r.html, available on GitHub https://github.com/roualdes/bridgestan, is installed, then 'BridgeStan' can be used to specify the target distribution to sample from.
Install
Health
- OK2026-08-0513 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE
- NOTE2026-08-0112 OK · 1 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE
- OK2026-04-2512 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE
- NOTE2026-03-1011 OK · 3 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE
Documentation
- Examples that run
- 100%
- Documented parameters
- 97%
- Return-value docs
- 100%
- References docs
- 36%
Downloads
Repository
Stars over time
Forks over time
Releases over time
Issues over time
PRs over time
Commits over time
Repository practices
7 development-tooling and community-health practices detected across 5 families in the upstream repository
Checks run against github.com/ucl/rmcmc on 2026-08-16.
Show all practices
Dependencies
Nothing depends on this yet.
Code & Tests
People & History
2 releases. Pick two to compare their code metrics. R releases are shown for context.
- RR 4.6.0 released · 2026-04-24
- 0.1.2Latest
- RR 4.5.0 released · 2025-04-11
- 0.1.12025-02-04
- RR 4.4.0 released · 2024-04-24
Package metadata
- First published
- 2025-02-04
- Total releases
- 2 / 1 yrs
- License
- MIT + file LICENSE OSI
- Download size
- 212 KB
- Installed size
- not tracked yet
- With dependencies
- not tracked yet
Cite
Cite this package
Run in R for the authors' preferred citation:
citation("rmcmc")This is what citation() produces when a package has no citation file of its own. If it prints something else, use that.
Cite the R Observatory
For a number measured here: a download total, a coverage figure, an archival date.
From data release v2026-08-21, which the citation names so these numbers can be found later. More on citing and the projects behind them.