An independent Gamma proposal

Suppose the target is \operatorname{Gamma}_{\mathrm{sc}}(\alpha,\beta) with shape \alpha and scale \beta. Describe an independent Metropolis–Hastings sampler using the proposal \operatorname{Gamma}_{\mathrm{sc}}(\gamma,\gamma/\alpha). Derive the Hastings ratio rather than merely quoting the generic formula.

Question. Suppose the target is \operatorname{Gamma}_{\mathrm{sc}}(\alpha,\beta) with shape \alpha and scale \beta. Describe an independent Metropolis–Hastings sampler using the proposal \operatorname{Gamma}_{\mathrm{sc}}(\gamma,\gamma/\alpha). Derive the Hastings ratio rather than merely quoting the generic formula.

Solution. Under the shape–scale convention, the target and proposal densities have kernels \begin{align*} \pi(z)&\propto z^{\alpha-1}e^{-z/\beta},\\ g(z)&\propto z^{\gamma-1}e^{-z/\lambda}, \qquad \lambda=\frac{\gamma}{\alpha}, \end{align*} for z>0. The proposal does not depend on the current state, so this is an independence sampler. If the current state is x and Y\sim g is proposed, then \begin{align*} r(x,Y) &=\frac{\pi(Y)g(x)}{\pi(x)g(Y)}\\ &=\frac{Y^{\alpha-1}e^{-Y/\beta}} {x^{\alpha-1}e^{-x/\beta}} \frac{x^{\gamma-1}e^{-x/\lambda}} {Y^{\gamma-1}e^{-Y/\lambda}}\\ &=\left(\frac{Y}{x}\right)^{\alpha-\gamma} \exp\!\left[(Y-x)\left(\frac1\lambda-\frac1\beta\right)\right]\\ &=\boxed{ \left(\frac{Y}{x}\right)^{\alpha-\gamma} \exp\!\left[(Y-x)\left(\frac{\alpha}{\gamma} -\frac1\beta\right)\right]}. \end{align*} Accept Y with probability \min\{1,r(x,Y)\}; otherwise retain x.

Parameterisation check

On these pages \operatorname{Gamma}(a,b) means shape a and rate b, with density proportional to z^{a-1}e^{-bz}. This exercise explicitly declares scale parameters. If the proposal’s second argument \gamma/\alpha were instead read as a rate, its kernel would be z^{\gamma-1}e^{-(\gamma/\alpha)z} and the final exponential coefficient would be \gamma/\alpha-1/\beta. The algorithm is not defined numerically until that convention is fixed.