Questions tagged [markov-chain-montecarlo]

Markov Chain Monte Carlo (MCMC) refers to a class of simulation methods for generating samples from a complex target distribution by generating random numbers from a Markov Chain whose stationary distribution is the target distribution. MCMC methods are typically used when more direct methods for random number generation (e.g. inversion method) are infeasible. The very first MCMC method was the Metropolis (et al.) algorithm, later expanded by Hastings.

Filter by
Sorted by
Tagged with
0 votes
0 answers
10 views

MCMCglmm package [closed]

the summary() for my ordinal model isn't returning all of my cutpoints. There are four levels in my response variable but I'm only getting two cut points. Does anyone know why?
smithx's user avatar
  • 1
0 votes
0 answers
13 views

SMC sampler weights when $K_n$ leaves $\pi_{n-1}$ invariant

I cannot seem to find this proof anywhere. Suppose I choose $K_n$ to leave $\pi_{n-1}$ invariant, and $L_{n-1}$ to be the reversal kernel. I want to show that the incremental weights $$ w_n(x_{n-1}, ...
Physics_Student's user avatar
1 vote
1 answer
32 views

Adjustment needed for multivariate Dvoretzky–Kiefer–Wolfowitz inequality on MCMC samples?

I was thinking about studying bounds on the multivariate empirical cumulative distribution function for samples from an MCMC chains. The multivariate Dvoretzky–Kiefer–Wolfowitz inequality would seem ...
Galen's user avatar
  • 6,989
0 votes
1 answer
26 views

How to diagnose HMC results like r-hat for a Mixture Model?

I have the following distribution $$ \begin{align} \boldsymbol \pi&\sim\text{Dirichlet}([1,\cdots 1]\in R^K)\\ \boldsymbol \theta&\sim P(\boldsymbol \theta) \\ \mathbf y&\sim \sum _{i=1}^K\...
wd violet's user avatar
  • 601
0 votes
1 answer
30 views

Jacobian and proposal ratio of Birth/death step in RJMCMC of Gaussian mixture model

I am asking questions regarding RJMCMC several times in this site. Some of my questions are answered and some are unanswered. It didn't clarify all of my unclear points but I am glad that I have ...
Kyungmin's user avatar
0 votes
0 answers
78 views

Using mcmc to estimate parameters of Dirichlet distribution

We have a probabilistic model with two parameters, $\theta$ and $\eta$, both of which are uniformly distributed between 0 and 1. The model has five possible outcomes, and the probability of each ...
user2880786's user avatar
0 votes
0 answers
11 views

Calculate acceptance ratio of Jacobian of split-merge RJMCMC

I am keep studying the RJMCMC and want to ask question regarding the acceptance ratio of split/merge step of RJMCMC The split/merge step, suggested by Richardson and Green (1997) is following for w_j, ...
Kyungmin's user avatar
0 votes
1 answer
34 views

Assumptions and setting for bayesian mixture model (for RJMCMC)

I want to understand about Bayesian mixture model discussed in RJMCMC paper (Richardson and Green, 1997) (https://academic.oup.com/jrsssb/article/59/4/731/7083042) I also posted similar question ...
Kyungmin's user avatar
0 votes
0 answers
9 views

Meaning and importance of 'Gibbs update' in MCMC

I am studying MCMC by "Handbook of Markov Chain Monte Carlo" by Brooks, Gelman This book is nice to explaining many fundamental concepts regarding MCMC. Especially in first chapter, they ...
Kyungmin's user avatar
4 votes
1 answer
185 views

Terms and assumptions in trans-dimensional MCMC (RJ-MCMC) for Green 1995 paper

I want to use Trans-dimensional MCMC in my research and for fundamental understanding, I am trying to learn from Green (1995) paper, which is foundation of RJ-MCMC. In part of 3.3 'switching between ...
Kyungmin's user avatar
0 votes
0 answers
28 views

Adaptive Metropolis For Multidimensional Parameter

Hi recently I want to implement the adaptive Metropolis algorithm. However I dont know how to deal with multidimensional parameters. The normal step of the adaptive MCMC is to update the covariance ...
stander Qiu's user avatar
0 votes
0 answers
5 views

Which method should be used to determine the class ID of multiple SVM models?

I'm using Support Vector Machine(SVM) with image classification. Each SVM model results a linear model $$y = wx + b$$ Where $w$ and $b$ is the SVM parameters. If I have multiple SVM models, I will get ...
euraad's user avatar
  • 349
0 votes
0 answers
22 views

Sampling from a Gaussian mixture (toy example ) using MALA

Say I want to sample from a Gaussian mixture $$\pi=\sum_{i=1}^3w_i\mathcal N(x_i,\sigma_i^2I_2)\tag1$$ where he support of the 3 distributions are "effectively separated"; e.g. $w_1=.1$, $...
0xbadf00d's user avatar
0 votes
0 answers
59 views

Trying to understand Reversible Jump MCMC

As stated in the foundational Biometrika paper of Green (1995) 'Reversible Jump Monte Carlo Calculation and model discrimination' I am researching the inversion of the data in Geophysics and MCMC is ...
Kyungmin's user avatar
0 votes
0 answers
19 views

Bayesian CI - isn't it by definition a bootstrapped or robust enough confidence interval? or should it be optimized?

As the title said, I've been wondering about bayesian methods, particularly MCMC, which seems to rely on sampling of the sample via chained iterations. Do we need an optimized/robust CI when running ...
user394092's user avatar
0 votes
0 answers
12 views

Epistemic Uncertainty for branch-and-bound methods

I want to ask some leads on how to quantify or propagate an epistemic type of uncertainty (e.g. statistical uncertainty) when performing a branch-and-bound (sort of fault tree analysis). The ...
ian's user avatar
  • 11
0 votes
0 answers
18 views

How to specify dyad and subject ID random factors in an MCMC model in R?

I am working on a model to analyze a categorical outcome variable (7 categories) for a design with two fixed factors (Condition and Group) as well as the random factors of Subject ID nested in Dyad ID....
R.Newbie's user avatar
0 votes
0 answers
10 views

MCMC predict volatility with GARCH

This is using MCMC (MH) algo to predict volatility from GARCH model: https://www.oreilly.com/library/view/machine-learning-for/9781492085249/ch04.html For simplication, consider (0,10)-GARCH (only ...
user6703592's user avatar
  • 1,245
1 vote
1 answer
95 views

Writing MCMC Sampling Code by Hand

I am trying to understand the steps involved in the Metropolis-Hastings Algorithm and trying to learn how to implement it myself. As an example, suppose I am interested in estimating the "...
stats_noob's user avatar
0 votes
0 answers
14 views

Simulate SDE without error

Let $d,k\in\mathbb N$; $\sigma\in C^1(\mathbb R^d,\mathbb R^{d\times k})$ be Lipschitz and $\Sigma:=\sigma\sigma^\ast$; $(W_t)_{t\ge0}$ be a $k$-dimensional Brownian motion; $\lambda$ denote the ...
0xbadf00d's user avatar
2 votes
1 answer
46 views

Why do we need to scale the variables in a Bayesian model?

In a Bayesian MMM model using pymc3 the variables are scaled. It is said that scaling helps in improving the efficiency of the MCMC algorithm. Also, it is stated that setting priors for the non-scaled ...
T_S's user avatar
  • 21
0 votes
0 answers
26 views

What is the trace in a Bayesian Model?

I am studying a python library that uses Bayesian inference to identify the coefficient of a linear regression. I have two questions, one very broad and one more vertical on MCMC and numpyro. What is ...
Andrea Ciufo's user avatar
0 votes
0 answers
19 views

Is it okay to merge seperate MCMC chains, using different seed value? [duplicate]

I'm new to Bayesian analysis. I'm trying to estimate species's abundance. As I know, when using MCMC sampling, it is recommended to make more than three chains. However, the function I use can make ...
pineapple159's user avatar
0 votes
0 answers
23 views

Combination of a discrete and a continuous Markov Chain in a MCMC

Recently, I've been questioning myself on the possibility of combining a discrete update and a continuous update on a single MCMC. Stephens (2000) in Algorithm 3.2 runs the process for a fixed amount ...
nico's user avatar
  • 1
0 votes
0 answers
17 views

Non-reversible MCMC based on diffusion dynamics

Given that the current sample location is $x\in[0,1)^d$, I would like to take the next sample $y$ as $$y=x+b(x)\Delta t+\sigma(x)\sqrt{\Delta t}\xi\;;\;\;\;\xi\sim\mathcal N_{0,\:I_d}\tag1$$ for some ...
0xbadf00d's user avatar
0 votes
0 answers
25 views

Nesting in bayesian inference

I am currently trying to develop a model that takes into account different data sets that are not directly comparable. More specifically, my model needs to describe the amount of a drug in the blood, ...
Jan's user avatar
  • 11
0 votes
0 answers
9 views

Arithmetic using summary means of the MCMC chains, differ from when I do the arithmetic directly using each row of the MCMC chains

I am trying to calculate the 'absolute risk difference' and 'needed to treat' (NNT). NNT is 1/(absolute risk difference) where the absolute risk difference is just the rate of an event in one ...
sol libes's user avatar
0 votes
0 answers
25 views

Can I use the output of an MCMC algorithm as the input of an independent Metropolis-Hastings algorithm?

Can I and if so, how can I, use the output of a MCMC method as the input for an independent Metropolis-Hastings algorithm? Maybe this question reduces to: How can I get (independent? or at least "...
0xbadf00d's user avatar
0 votes
0 answers
10 views

When to stop MCMC within collapsed Gibbs?

I am setting up a Hierarchical model whose target distribution is $p(\theta,w|y)$, $\theta$ being a reduced set of high-level parameters, $w$ being a data augmentation of very high dimension, and $y$ ...
SCS's user avatar
  • 1
1 vote
0 answers
29 views

What kind of sampling is using a sample from a Uniform distribution to accept and reject [closed]

Given a sampler from a uniform distribution $U(0,1)$ and the target Bernoulli distribution $b(p)$ with two targets $+1,0$ , what kind of sampling technique is: Sample $u_n\sim U(0,1)$ If $u_n<p$: ...
user1176663's user avatar
0 votes
0 answers
12 views

Single walker MCMC using emcee

Does anyone know if it is possible to use the MCMC implementation emcee in python with only a single walker given 15 parameters? Or do I have to use a different implementation? I want to do this as I ...
Jan's user avatar
  • 11
2 votes
0 answers
36 views

Bayesian variant of Ljung-Box test?

I am using Bayesian MCMC estimation methods for GARCH models and I want to check, if model residuals are uncorrelated. In classical frequentist approach, one would use standard Ljung-Box test to check ...
Alex Slavik's user avatar
2 votes
1 answer
25 views

How can I pool Bayesian parameter estimates after multiple imputation?

After multiple imputation (imputed dataset = 20), I would like to conduct Bayesian Model Estimation with Adaptive Metropolis Hastings Sampling (amh) -- using the MCMC method. How can I pool the ...
conner's user avatar
  • 21
2 votes
2 answers
111 views

How does Rao-Blackwellization of the Metropolis-Hastings algorithm work?

I've read the paper A vanilla Rao-Blackwellization of Metropolis-Hastings algorithms, but I don't get what their actually suggested estimator is. To give some detail, we are considering the following ...
0xbadf00d's user avatar
0 votes
0 answers
41 views

Random scan Gibbs sampling as special case of Metropolis-Hastings

I am reading Blitzstein's Introduction to Probability and come across with the following proof that I don't really understand: Theorem: The random scan Gibbs sampler is a special case of the ...
Borcherdsbb's user avatar
0 votes
0 answers
27 views

Monte Carlo simulation to get stationary distribution of a complex system

I was wondering if I could get some help with my problem. I have a complex Markov chain where I cannot track its transition analytically. Instead, I decided to simulate $N$ numbers of particles for $T$...
Anonymouslylost's user avatar
0 votes
0 answers
27 views

Does Hamiltonian Monte Carlo explore the target distribution uniformly?

I am trying to incorporate HMC into an algorithm that requires me to generate samples that are uniformly distributed in the distribution being sampled. Ie, the samples are not necessarily uniformly ...
Dirk's user avatar
  • 1
1 vote
0 answers
47 views

Metropolis Hastings Algorithm and Breaking Reversibility in MCMC

If the goal is to sample from a distribution $\pi$ it is common to build a Markov Chain with stationary distribution $\pi$. Solving this problem using Markov Chain Monte Carlo is essentially ...
σκουλήκι's user avatar
0 votes
0 answers
18 views

non-reversible (irreversible) MCMC Langevin sampling methods. Intuition

Mathematically it is well understood that irreversible samplers are superior to reversible samplers in a number of ways. For example, if we want to sample from a distribution $\pi \propto e^{-U}$ by ...
σκουλήκι's user avatar
1 vote
0 answers
35 views

Could one use mixtures of Gaussians to turn MCMC posterior samples into a new prior?

Theoretically in Bayesian inference one could use one experiment's posterior as another experiment's prior, such that knowledge of the parameters accumulates from $p(\theta) \rightarrow p(\theta|\...
Durden's user avatar
  • 797
0 votes
0 answers
17 views

Estimation with Random Walk 2 Priors

In (https://becarioprecario.bitbucket.io/inla-gitbook/ch-smoothing.html#sec:smoothterms), they show an example of a Random Walk 2 (RW2) prior being used on the LIDAR dataset. For the model set-up, we ...
user1848065's user avatar
2 votes
1 answer
68 views

How can I sample a multivariate normal vector that satisfies a linear equality constraint?

Let $X \sim N_n(\mu, \Sigma)$, such that $AX=b$ where $A$ is a ($p \times n$) matrix, with $p \ll n$. How can I efficiently sample from this distribution? I've seen techniques using elliptical slice ...
J. Zeitouni's user avatar
3 votes
2 answers
72 views

In Bayesian linear regression Advantages of predictive posterior compared to posterior of model coefficients

In Bayesian linear regression, if we want to get confidence intervals for predictions of a new observation. I was thinking of the following two options. Use the quantiles from samples sampled from ...
Dylan Dijk's user avatar
0 votes
0 answers
27 views

Subtilities of MCMC method and more generally about covariance matrix and Samplers

i have difficulties to better understand about what we commonly called a sampler, especially how to produce a covariance matrix between parameters during a MCMC code run. In MCM, I know that we start ...
guizmo133's user avatar
0 votes
0 answers
12 views

Is it possible to increase the Hastings ratio by combining and mixing elementary kernels?

Let's say I am working with a state $X$ split into three parts $U$, $V$, and $W$. I can efficiently sample from $W|U,V$, $U|V$, and $V|U$. My initial intuition was to do a variable-at-a-time ...
J. Zeitouni's user avatar
1 vote
0 answers
19 views

What is the intuition for the limited variation in potential energy for HMC?

In A General Metric for Riemannian Manifold Hamiltonian Monte Carlo (Betancourt, 2013), the author writes: The first [5] and still most common choice of the conditional density, $\pi(p|q)$, is a ...
Tim Hargreaves's user avatar
0 votes
0 answers
10 views

Estimating integrated-out variables

An illustration David Blei in his lecture notes considers a collapsed Gibbs sampler for a Gaussian mixture model. In this case $B = (\mu_1, \dotsc, \mu_K)$ is a latent vector of means and $A = (Z_1, \...
Paweł Czyż's user avatar
1 vote
0 answers
15 views

Gibbs sampler, how to generate samples based on odds?

I am reading a paper that contains a Gibbs sampler for a regression model with parameters $\beta$ and design matrix $X$. One of the steps in the Gibbs sampler requires simulating from a binary random ...
Moncho's user avatar
  • 11
0 votes
0 answers
22 views

blue noise error distribution in (MC)MC estimation

In computer graphics, you have an (MC)MC estimate $Q_i$ of the color value of the $i$th pixel and a true value $I_i$. Now you take $\epsilon_i:=Q_i-I_i$, which can be thought of as an "error ...
0xbadf00d's user avatar
1 vote
0 answers
47 views

Gibbs Sampler Initialization

I am trying to implement a Gibbs sampler with three blocks, that's not actually a full conditional Gibbs sampler. Say I partitition my parameter $X$ into three: {$X_1$, $X_2$, $X_3$}. I inted to ...
J. Zeitouni's user avatar

1
2 3 4 5
33