# Full conditionals - Gibbs Sampler

i want to draw samples from a 5-dimensional posterior distribution $f(k,\theta,\lambda,b_1,b_2|Y=y)$. From Bayes-Theorem there is the following relationship between posterior and likelihood:

posterior $\propto$ likelihhod $\times$ prior

so the full conditional of $\theta$ is

$f(\theta|k, \lambda, b_1, b_2, Y=y) \propto f(Y|\theta,\lambda,k,b_1,b_2) \cdot f(\theta)$ ?

i can now transform this to a Gamma distribution by by ignoring all terms that are constant with respect to the parameter right ?

• Yes you can ignore terms not involving the parameter. About the Gamma distribution we cannot answer without seeing $f$. – Stéphane Laurent Mar 26 '15 at 11:08
• hey stephane thanks, yeah u are right, u cant answer it without seeing f :). but the formula of the full conditional is correct ? – user2016445 Mar 26 '15 at 11:10
• This formula is correct assuming prior independence between $\theta$ and the other parameters. – Stéphane Laurent Mar 26 '15 at 11:42
• can u please explain why do i need there the independence of the priors to get this formula ? – user2016445 Mar 26 '15 at 11:51
• You have a prior on $(\theta,k,\lambda,b_1,b_2)$. If there is independence then it has form $\pi(\theta)\pi(k,\lambda,b_1,b_2)$ and you can drop the second factor when ignoring things not involving $\theta$. – Stéphane Laurent Mar 26 '15 at 11:57

Let me set $\theta_1=\theta$ and $\theta_2=(k,\lambda,b_1,b_2)$ for the sake of lightness.
Bayes formula: $$\pi(\theta_1,\theta_2\mid y) \overset{\theta_1,\theta_2}{\propto} f(y \mid \theta_1,\theta_2) \pi(\theta_1,\theta_2)$$.
The notation $\overset{\theta_1,\theta_2}{\propto}$ is not standard. I invented myself after I faced a situation for which the naked symbol $\propto$ was ambiguous. It means that both members are proportional as functions of $(\theta_1,\theta_2)$.
By standard measure theory, the full conditional distribution of $\theta_1$, that is to say $\pi(\theta_1,\mid y, \theta_2)$ is given by the proportionality relation $$\pi(\theta_1,\mid y, \theta_2) \overset{\theta_1}{\propto} \pi(\theta_1,\theta_2\mid y),$$ then by Bayes formula previously recalled: $$\boxed{\pi(\theta_1,\mid y, \theta_2) \overset{\theta_1}{\propto} f(y \mid \theta_1,\theta_2) \pi(\theta_1,\theta_2)}.$$
Thus your formula is wrong in general. But if you use independent priors on $\theta_1$ and $\theta_2$ then the prior distribution has form $\pi(\theta_1,\theta_2)=\pi(\theta_1)\pi(\theta_2)$ (this is not the same "$\pi$" occuring three times here : "$\pi$" means "pdf of") and it is proportional to the prior $\pi(\theta_1)$ as a function of $\theta_1$: $$\pi(\theta_1,\theta_2)=\pi(\theta_1)\pi(\theta_2) \overset{\theta_1}{\propto} \pi(\theta_1)$$ and the general boxed formula reduces to your formula in this case: $$\pi(\theta_1,\mid y, \theta_2) \overset{\theta_1}{\propto} f(y \mid \theta_1,\theta_2) \pi(\theta_1).$$