Questions tagged [metropolis-hastings]

A special type of Markov Chain Monte Carlo (MCMC) algorithm used to simulate from complex probability distributions. It is validated by Markov chain theory and offers a wide range of possible implementations.

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

What is the difference between the transition kernel and the proposal density?

When considering MCMC, could someone explain the difference between the transition kernel and the porposal density for me please? Proposal density is the function we use to sample from the proposal ...
1
vote
0answers
19 views

Proposal Function For Variables That Sum To 1 (Dirichlet Prior)

Recently I've been trying to use MCMC to infer a set of 50 random variables (species frequencies) that sum to 1 with the Metropolis-Hastings algorithm. However, the algorithm is not working well ...
1
vote
2answers
59 views

How to use the MCMC method for multivariate distributions?

I wish to find the posterior of a joint distribution of 4 parameters whose prior and likelihoods are known, but I do not understand how to accept and reject samples, in any other case other than ...
1
vote
0answers
8 views

proposal value between the generated data and the accepted previous proposal

I have a question here that has been confusing me these two days. So in mcmc hasting metropolis if a proposal value was accepted which means tha it's going to be the current value after that ...
2
votes
0answers
60 views

Estimating the asymptotic variance of a specific Metropolis-Hastings estimator

Remark: I've added a detailed description of the actual setting of the application to the end of the question. I'm running the Metropolis-Hastings algorithm with target distribution $\hat\mu$ (see ...
2
votes
1answer
42 views

Do I need to evaluate acceptance rates in Metropolis within Gibbs algorithm?

Consider the Gibbs sampler Sample $\theta' \sim p(\theta|\tau, D)$ Sample $\tau' \sim p(\tau|\theta', D)$ where $\theta,\tau$ parameters of the data $D$. Now assume that we can only sample from $p(\...
0
votes
1answer
36 views

Can a Metropolis-Hastings estimator converge if the proposal density vanishes whenver the target density vanishes?

I'm running the Metropolis-Hastings algorithm for a target and proposal density $p$ and $q$, respectively, for which it holds $$p(y)=0\Rightarrow q(x,y)=0\;\;\;\text{for all }y.\tag1$$ By definition ...
0
votes
1answer
24 views

Proof of convergence in original Metropolis algorithm paper

I've been trying to understand the original paper in which the Metropolis algorithm was proposed, specifically the proof of convergence given in section II. The final step in the proof gives the ...
1
vote
0answers
39 views

Can we find an asymptotically consistent Metropolis-Hastings estimator based on this proposal scheme?

I'm running the Metropolis-Hastings algorithm for a target distribution $\hat\mu$ (see below for the formal setup including the definition of $\hat\mu$) on a product space $I\times E'$. I'm using the ...
2
votes
0answers
92 views

Can we use of the Metropolis-Hastings importance sampling estimator here?

EDIT: Note that proposing according to $\hat Q$ is equivalent to the following scheme: Given the current state $\tilde x=(i,x')\in\tilde E:=I\times E'$ and $x:=\varphi_i(x')$, sample $j\sim\tilde T(\...
2
votes
2answers
85 views

Uniform random vector with zero sum restriction?

I'm building a Metropolis transition kernel and figured out I would need a very specific distribution for optimal results. How can I construct a random vector $(U_1, U_2, \dots, U_n)$ such that $\...
2
votes
1answer
82 views

Erroneous expression for Metropolis-Hastings acceptance ratio in a paper

Let $(E,\mathcal E)$ be a measure space; $\rho:E\to[0,\infty)$ be $\mathcal E$-measurable, $p:E^2\to[0,\infty)$ be $\mathcal E^{\otimes2}$-measurable, $$r(x,y):=\left.\begin{cases}\displaystyle\frac{\...
0
votes
0answers
38 views

How do I use the MCMC method to find the joint posterior of 4 parameters ($\lambda$,$\lambda_s$,$\mu$,$\beta$) of exponential distributions

Essentially, the problem statement is as follows. I have 2 functions in reliability theory called MTTF(Mean time to failure) and Availablity, both with inputs as $\lambda$,$\lambda_s$,$\mu$ & $\...
0
votes
0answers
30 views

Is that possible that I use an arbitrary prior distribution that is not conjugate to the likelihood and do mcmc sampling?

In Bayesian Statistics, we can use conjugate priors to the likelihood functions, then we can get the posterior distributions which are the same distributions as the prior distributions. I wonder ...
2
votes
1answer
68 views

Random Walk Metropolis Hastings implementation in R using log scale

Context I looked literally everywhere but I couldn't find a complete implementation of the Random Walk Metropolis-Hastings algorithm using the log scale. By log scale I mean that we are working with ...
2
votes
0answers
33 views

Can we use Gelman-Rubin diagnostic to assess convergence of parallel tempered chains in MCMC?

I know that the principle behind the Gelman-Rubin diagnostic is comparing within-chain and between-chain variances and if the potential scale reduction factor is less than, say 1.1 or 1.05 then the ...
2
votes
0answers
22 views

Asymptotic convergence of the Metropolis-Hastings algorithm with a not necessarily positive target density

Consider the Metropolis-Hastings algorithm on a general state space. Let $p$ denote the density of the target distribution $\mu$, $(X_n)_{n\in\mathbb N_0}$ denote the generated Markov chain and $\...
2
votes
1answer
49 views

Proposal Metropolis distribution for complex Bayesian models

In the book Uncertainty Quantification: Theory, Implementation, and Applications, by R.C. Smith, there is a chapter about Bayesian inference. The likelihood is Gaussian, with error variance $\sigma^2$ ...
0
votes
1answer
49 views

What does MCMC do during burn-in period?

I am studying mcmc and I am wondering what mcmc does during burn-in period. And also what is the difference during burning period and after the burn-in period?
5
votes
0answers
50 views

Keeping track of the variance of a Metropolis-Hastings estimator

Let $(E,\mathcal E,\lambda)$ and $(E',\mathcal E',\lambda')$ be measure spaces, $p,q$ be probability densities on $(E,\mathcal E,\lambda)$, and $\varphi:E'\to E$ be bijective and $(\mathcal E',\...
2
votes
2answers
54 views

Need to understand a statement for Random Walk Metropolis algorithm's proposal distribution?

I was told that the proposal distribution of Random Walk Metropolis needs to be symmetric. But today I was reading a book about Bayesian Analysis which contains the following statement: "The proposal ...
0
votes
1answer
42 views

Confused about how Random Walk Metropolis algorithm work?

The following picture explains how the Random Walk Metropolis algorithm walk throughout time from $ t=1 $ to $ t=99 $. At times $ t=1 $ and $ t=2 $, things are fine to understand, somehow, I am lost ...
1
vote
1answer
44 views

Unbiased Metropolis-Hastings estimator of the form $\frac{\sum_{i=1}^nW_if(Y_i)}{\sum_{i=1}^nW_i}$. How do we need to choose $W_i$?

Let $(X_n)_{n\in\mathbb N_0}$ be the Markov chain generated by the Metorpolis-Hastings algorithm with proposal kernel $Q$ and target distribution $\mu$ and $(Y_n)_{n\in\mathbb N}$ denote the ...
0
votes
0answers
21 views

Can we use a Dirac kernel in the proposal of the Metropolis-Hastings algorithm?

I'm running the Metropolis-Hastings algorithm on a product space $(I\times E,2^I\otimes\mathcal E,\zeta\otimes\lambda)$, where $I$ is a finite nonempty set and $\zeta$ denotes the counting measure. ...
3
votes
1answer
120 views

How to tune MCMC with unwieldy posterior [duplicate]

Let's say I have $n$ observations of a random variable, $X_1, \dotsm, X_n \sim \mathcal{N}(0, \sigma^2)$. I also assume $\sigma^2$ has a Gamma(1,1) prior distribution, $\pi(x) = \exp(-x)$. I'm now ...
0
votes
0answers
18 views

Sampling a proposed value with a limited range target when running MCMC [duplicate]

I want to do an MCMC algorithm and need to sample a proposed value from a proposed distribution. In the Metropolis algorithm, people usually use a normal distribution as proposal. But if the prior ...
1
vote
0answers
16 views

Is it correct to perform multiple swaps simultaneously in Parallel Tempering?

In Parallel Tempering, after every $N_{swap}$ iterations of running Metropolis method, we randomly select a temperature $T_i$ and swap its configuration with $T_{i+1}$ with a probability min(1, exp (∆...
1
vote
1answer
63 views

Does the following can be considered a Metropolis Method? [closed]

Suppose, from the current state C it is possible to move to D different neighbouring states. In simulated annealing, we select a neighbouring state $D_i$ randomly and then accept it with probability $...
1
vote
0answers
58 views

Minimizing the rate of geometric ergodicity of a Metropolis-Hastings kernel

Let $\kappa$ denote the transition kernel of the symmetric Metropolis-Hastings algorithm with proposal kernel $Q$ and target distribution $\mu$. What would be a general guideline if we're aiming to ...
1
vote
0answers
27 views

Upper bound for the asymptotic variance in the central limit theorem for a Metropolis-Hastings chain

Let $(E,\mathcal E,\lambda)$ be a measure space, $Q$ be a Markov kernel on $(E,\mathcal E)$ with $$Q(x,B)=\int_B\lambda({\rm d}y)q(x,y)\;\;\;\text{for all }(x,B)\in E\times\mathcal E$$ for some ...
2
votes
0answers
42 views

Is the Metropolis-Hastings kernel always aperiodic, irreducible and geometrically ergodic?

Let $(E,\mathcal E,\lambda)$ be a measure space, $Q$ be a Markov kernel on $(E,\mathcal E)$ with $$Q(x,B)=\int_B\lambda({\rm d}y)q(x,y)\;\;\;\text{for all }(x,B)\in E\times\mathcal E$$ for some ...
1
vote
0answers
41 views

Does a Metropolis-Hastings chain always obey a central limit theorem?

Let $(E,\mathcal E,\lambda)$ be a measure space, $Q$ be a Markov kernel on $(E,\mathcal E)$ with $$Q(x,B)=\int_B\lambda({\rm d}y)q(x,y)\;\;\;\text{for all }(x,B)\in E\times\mathcal E$$ for some ...
0
votes
0answers
29 views

Basics of JAGS metropolis hastings model with negative binomial

I'm having an insane time finding any documentation on JAGS models. As popular as it is, I imagine there has to be something out there. Still, I've searched for over an hour and cannot find even a ...
0
votes
2answers
67 views

Why is $\frac1n\sum_{i=0}^{n-1}\sum_{j=0}^i1_{\{\:X_i\:=\:Y_j\:\}}f(Y_j)$ an equivalent representation for the usual Metropolis-Hastings estimator?

At the beginning of section 2 of the paper A Vanilla Rao-Blackwellization of Metropolis-Hastings Algorithms, the usual Metorpolis-Hastings estimator of $\int f$ given by the ergodic average $\frac1n\...
1
vote
1answer
39 views

logistic mcmc start [closed]

I am doing logistic regression with MCMC . What is a good start for MCMC ?
0
votes
0answers
22 views

Choice of weights minimizing the asymptotic variance of a Metropolis-Hastings estimator (balance heuristic analogue)

I want to sample from a probability density $p$ on a measure space $(E,\mathcal E,\lambda)$. Sampling directly from $\mu:=p\lambda$ is not possible and hence I want to estimate $\mu$ by the Metropolis-...
0
votes
1answer
39 views

Why does my implementation of the Metropolis algorithm converge incorrectly for a non-uniform prior distribution?

I am trying to estimate the integral of sine from $0$ to $\pi$ using the Metropolis algorithm from a prior distribution of $p(x) = e^{-(x-\pi/2)^2}$ $$\int_0^\pi \sin(x)\,\text{d}x$$ The integral ...
-1
votes
1answer
56 views

Integrating with Metropolis-Hastings [closed]

I am trying to implement a Metropolis routine to evaluate simple integrals. While it seem that the Markov chains I obtain reproduce the correct function, the area is simply wrong. Suppose I want to ...
0
votes
0answers
45 views

Minimization of the asymptotic variance of a Metropolis-Hastings waste-recycling estimator

Let $\alpha$ denote the acceptance function of the Markov chain $(X_n)_{n\in\mathbb N_0}$ generated by the Metropolis-Hastings algorithm with proposal kernel $Q$ and target distribution $\mu$$^1$ and $...
0
votes
0answers
20 views

Is the stationary distribution of the augmented Metropolis-Hastings kernel even reversible in the symmetric proposal case?

Let $\alpha$ denote the acceptance function of the Markov chain generated by the Metropolis-Hastings algorithm with proposal kernel $Q$ and target distribution $\mu$$^1$ and $$\kappa_{\text{aug}}((x,y)...
1
vote
1answer
72 views

Implementing a Hit-And-Run MCMC Sampler in Python

I'm trying to implement the Metropolisized Hit-And-Run Sampler as described in Chapter 7.2 of Chen and Schmeiser, Performance of the Gibbs, Hit-and-Run, and Metropolis Samplers https://www.jstor.org/...
3
votes
1answer
90 views

Central limit theorem for a Metropolis-Hastings estimator

Let $\alpha$ denote the acceptance function of the Markov chain $(X_n)_{n\in\mathbb N_0}$ generated by the Metropolis-Hastings algorithm with proposal kernel $Q$ and target distribution $\mu$$^1$ and $...
0
votes
1answer
20 views

For very basic Metropolis Algorithm with one parameter, what happens when you are at the tail?

I'm not sure how to phrase the question, but let's say you are running the Metropolis Algorithm and the distribution you are trying to produce is just a single distribution. Let's say the values of ...
0
votes
0answers
81 views

Sampling from/near boundary of a region in R^n

Suppose $\Omega$ is a region in $\mathbb R^n$, and suppose we are given a function $\chi(x)$ with $\chi(x)=1$ if $x\in \Omega$ and $\chi(x)=0$ otherwise. If it helps we can assume $\Omega\subseteq B$ ...
0
votes
0answers
19 views

the convergence speed for a Markov chain

For a metropolis hastings algorithm, suppose that the stationary distribution is defined as the Gibbs Boltzmann distribution $\pi_T(x)= \frac{1}{Z_T}e^{-\frac{V(x)}{T} }$ where $Z_T = \sum_{y\in V} e^{...
6
votes
2answers
124 views

Using all Metropolis-Hastings proposals to estimate an integral

Suppose we run the Metropolis-Hastings with target distribution $\mu$ to compute the integral $\int f\:{\rm d}\mu$. Usually, we use the estimator $$A_n:=\frac1n\sum_{i=0}^{n-1}f(X_i).$$ However, ...
0
votes
1answer
91 views

Could someone help me to understand the Metropolis-Hastings algorithm for discrete Markov Chains?

Metropolis-Hastings Algorithm Assume the Markov chain is in some state $X_{n} = i$. Let $\textbf{H}$ be the transition matrix for any irreducible Markov chain on the state space. We generate $X_{n+1}$...
2
votes
0answers
26 views

Minimization of the asymptotic variance in MCMC

Suppose $(X_n)_{n\in\mathbb N_0}$ is a Markov chain generated by the Metropolis-Hastings algorithm. Assume $(X_n)_{n\in\mathbb N_0}$ is stationary and consider the ergodic averages $$A_n:=\frac1n\sum_{...
1
vote
1answer
41 views

What does it mean to have assymetric proposal distributions when coding the Metropolis-Hastings Algorithm?

The Metropolis-Hastings algorithm is a generalization of the older Metropolis algorithm. As part of these algorithms, they compute a ratio called the Metropolis ratio: $$ r = \frac{P(x')}{P(x)}\frac{...
2
votes
1answer
45 views

Convergence maximum of Normal rv to gumbel through simulation (metropolis hastings)

I would like to see the convergence of an order statistic to its respective Extreme Value attractor by simulating with the Metropolis Hastings algorithm (I am self-studying MCMC algos). I was trying ...

1 2 3 4 5 7