Re: [R] Bayesian logistic regression with a beta prior (MCMClogit)

From: francogrex <>
Date: Thu, 03 May 2007 13:49:05 -0700 (PDT)

Hi, yes but I realized afterwards that it's the logfun argument that had to be put to logfun=F and the logpriorfun function had to be log=F logpriorfun <- function(beta,shape1,shape2){ sum(dbeta(beta,shape1,shape2,log=F)) }

But that's just for that particular example. I find I am having problems still even after adjusting for that. Using other data it is not accepting the estimation of beta.start with maximum likelihood ("user.prior.density(beta.start) <= 0") and it is obliging me to specify it giving me a very narrow range, and hence the acceptance rate of the output is very mediocre (0.01)... I don't know I am missing something here maybe. As much as I was excited about the MCMCpack, I am finding that it is no substitute for BUGS/Brugs.

Cody_Hamilton wrote:
> Dear Franco,
> Have you tried using the beta.start option in MCMClogit? (The problem may
> be where you are starting your chain.)
> Regards,
> -Cody

View this message in context:
Sent from the R help mailing list archive at

______________________________________________ mailing list
PLEASE do read the posting guide
and provide commented, minimal, self-contained, reproducible code.
Received on Thu 03 May 2007 - 21:49:03 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 03 May 2007 - 23:31:52 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.