I conducted a Bayesian analysis in winbugs and then checked the convergence from the history plots. The regression coefficients look stabilized, but the variance parameters don't. I got the number of iteration up to 5000, but it still does not look stabilized. I attached the history plots of a regression coefficient and variances. Can you please tell me what I might be doing wrong? Or is is converged?

enter image description here

  • $\begingroup$ Ideally, you could provide a reproducible example (code, data pasted in or provided as a supplement) $\endgroup$ Mar 6, 2013 at 3:36

2 Answers 2


5000? That's nothing :-) In papers it is usual to use like 200,000. Variance parameters are always the worse for estimation. You have a huge autocorrelation in the chains - you should increase your thin parameter at least 16 times. What is your thin parameter now?

Anyway, I think the variables would converge quite well if you let the chains run longer. So set the thin and do at least 50,000 iterations.

  • $\begingroup$ Oh God! 200.000 could take hours :( $\endgroup$
    – Günal
    Jan 29, 2013 at 11:28
  • 3
    $\begingroup$ @Edo Or days. C'est la Gibbs. $\endgroup$ Jan 30, 2013 at 19:41
  • 2
    $\begingroup$ The model is likely to take hours to run, but even with that I suspect that phiA and tauA chains won't converge. They seem to exhibit poor mixing and autocorrelation. Sometimes long burn-ins and lots of thinning can solve this, but often doesn't in my experience. Centering or scaling to N(0, 1) can help. I'm actually looking for advice on what else to do to improve mixing and convergence in hierarchical Bayesian models, so someone else might be of more help. $\endgroup$
    – djhocking
    Feb 17, 2013 at 16:18

The second and third picture don't seem to converge. You can look at Rhat value. If it is 1.0, then it is converged. If it is far away from that, say 1.5, probably it doesn't converge.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.