[R-sig-ME] various priors for MCMCglmm
Ned Dochtermann
ned.dochtermann at gmail.com
Sat May 21 02:43:31 CEST 2011
Hi all,
I have had and continue to have a lot of difficulty with not only the
concept of priors but also their implementation for the MCMCglmm package.
While Jarrod has always been extraordinarily helpful with this--as well as
patient with those of us that seem eternally dense--I thought I'd list out
some of the specifications I've come across to perhaps ease the frequency
with which Jarrod has to reply to questions about priors.
I've specified, for ease, R=G and a single random effect. From things I've
read R is less sensitive to prior specification so this might be okay (?).
Since I'm still not comfortable with priors hopefully these can be clarified
by those more knowledgeable. I'm sure it would also be of general use if
other priors were added via replies.
The parts that are correct should be attributed to Jarrod. The parts that
are wrong should be attributed to my clumsy attempts to generalize something
he wrote. Some of this is just copied from posts to the listserv or Jarrod's
course notes but I thought it might be useful to summarize then in a single
place.
Hopefully none of this is too misleading but will be of some use to others.
Ned
--
Ned Dochtermann
Department of Biology
University of Nevada, Reno
ned.dochtermann at gmail.com
http://wolfweb.unr.edu/homepage/mpeacock/Ned.Dochtermann/
http://www.researcherid.com/rid/A-7146-2010
--
#Inverse Wishart (univariate)
prior.iw<-list(R=list(V=1, nu=1),G=list(G1=list(V=1, nu=1)))
#Inverse Wishart (multivariate, variables=x)
prior.miw<-list(R=list(V=diag(x), nu=x),G=list(G1=list(V=diag(x),
nu=x)))
#it came up in discussion that this prior can substantially affect the
posterior when there are few data
#I think that the following is an inverse Wishart for multiple response
variables that is less informative is:
prior.miw<-list(R=list(V=diag(x), nu=x, alpha.mu=c(0,0),
alpha.V=diag(x)*a),G=list(G1=list(V=diag(x), nu=x, alpha.mu=c(0,0),
alpha.V=diag(x)*a)))
#for this a should be "something large (e.g. 1000, depending on the scale of
the data)"
#Inverse Gamma (univariate)
prior.ig<-list(R=list(V=1, nu=0.002),G=list(G1=list(V=1, nu=0.002)))
#Inverse Gamma (multivariate, two variables)
prior.mig2<-list(R=list(V=diag(2),
nu=1.002),G=list(G1=list(V=diag(2), nu=1.002)))
#Inverse Gamma (multivariate, variables=x)
prior.migX<-list(R=list(V=diag(x),
nu=1.002),G=list(G1=list(V=diag(x), nu=1.002)))
#or
prior.migX<-list(R=list(V=diag(x),
nu=b.002),G=list(G1=list(V=diag(x), nu=b.002)))
#where b is x-1
#I initially thought the first of these was the way to go but I'm less so
now after looking at the
#univariate specification. Also, Gelman (2006. Bayesian Analysis.
1(3):515-533) suggests that
#there can be problems with this prior.
#flat covariance between two responses
prior.flatcor<-list(R=list(V=diag(2)*1e-6,
nu=3),G=list(G1=list(V=diag(2)*1e-6, nu=3)))
#to generalize this to x variables V would be diag(x) but I'm not sure if nu
would be x+1
#flat, uniform, prior for just a variance
prior.flatvar<-list(R=list(V=1e-16, nu=-2),G=list(G1=list(V=1e-16,
nu=-2)))
#another flat improper prior, equivalent to REML fitting:
prior.reml<-list(G=list(G1=list(V=1,nu=0)),R = list(V =1, nu = ))
#I've actually run the same univariate analysis with prior.reml and lmer and
gotten pretty much the same results
More information about the R-sig-mixed-models
mailing list