[R-sig-ME] MCMCglmm prior distributions

Jarrod Hadfield j.hadfield at ed.ac.uk
Mon Oct 20 16:17:59 CEST 2014


Hi Boby,

If you mean a common t-prior (with estimated scale) for the random  
effects then you cannot. All that you can do is place a fixed t-prior  
on the `fixed' effects.

Cheers,

Jarrod




Quoting Boby Mathew <bobyboby at gmail.com> on Mon, 20 Oct 2014 15:52:24 +0200:

> Dear jarrod hadfield,
>
> How can I pace  individual variances with a t-prior for the random effects?
> Could you please provide me an example?
>
> thanks for the help.
>
> regards,
> Boby
>
> On Mon, Oct 20, 2014 at 2:58 PM, Jarrod Hadfield <j.hadfield at ed.ac.uk>
> wrote:
>
>> Hi,
>>
>> This gives the b's a common variance. There is no point giving them
>> individual variances unless you want to treat them as `fixed' but place a
>> t-prior rather than a normal prior on each effect.
>>
>> Jarrod
>>
>>
>>
>>
>>
>> Quoting Boby Mathew <bobyboby at gmail.com> on Mon, 20 Oct 2014 14:42:02
>> +0200:
>>
>>  Dear Jarrod Hadfield,
>>>
>>> Here I have attached a small code with the simulation code. I want to
>>> estimate the effect of 'b' here. As you suggested I treated fixed effect
>>> as
>>> random and gave own variance. But I am not sure this is the right way.
>>>
>>> Could you please check whether the implementation is right?
>>>
>>> regards,
>>> Boby
>>>
>>> mark=100; line=150
>>>
>>> x=round(matrix(runif(mark*line),nrow=mark))
>>> b=rep(0,mark)
>>> b[8]=3; b[80]=5;b[90]=5;
>>>
>>> noise=rnorm(line,0,sqrt(1))
>>>
>>>
>>>
>>> Line=1:line
>>>
>>> y = b%*%x + noise
>>>
>>> Z=t(x)
>>>
>>> library(MCMCglmm)
>>>
>>> data=data.frame(Phe=t(y),animal=Line)
>>>
>>> data$animal=as.factor(data$animal)
>>>
>>>
>>> prior2.2 <- list(G = list(G1 = list(V = 1, n = 0.002)), R = list(V = 1, n
>>> =
>>> 0.002))
>>>
>>> mod_mcmc=MCMCglmm(Phe~1,random=~idv(Z),pr=T,data=data,
>>> nitt=50000,thin=500,burnin=10000,prior=prior2.2)
>>>
>>> val=colMeans (mod_mcmc$Sol)
>>>
>>>
>>>
>>>
>>> On Thu, Oct 16, 2014 at 5:51 PM, Jarrod Hadfield <j.hadfield at ed.ac.uk>
>>> wrote:
>>>
>>>  Hi Boby,
>>>>
>>>> In short - no. I haven't tried this (or thought about it much), but you
>>>> could treat each fixed effect as a single random effect with its own
>>>> associated variance component. Presumably, you could then specify the
>>>> prior
>>>> for the variance component in a way that induces a prior t-distribution
>>>> on
>>>> the effect. Like the Laplace it has fatter tails than the Normal, but it
>>>> lacks the peakiness and won't give some of the nice features of the
>>>> LASSO.
>>>>
>>>> Cheers,
>>>>
>>>> Jarrod
>>>>
>>>>
>>>>
>>>>
>>>> Quoting Boby Mathew <bobyboby at gmail.com> on Thu, 16 Oct 2014 16:06:13
>>>> +0200:
>>>>
>>>>  Dear MCMCglmm users,
>>>>
>>>>>
>>>>> Is it possible to use double exponential priors(Laplace) in MCMCglmm?
>>>>>
>>>>> Thanks for the helps.
>>>>>
>>>>> regards,
>>>>> Boby
>>>>>
>>>>>
>>>>> --
>>>>> Dr. Boby Mathew
>>>>> INRES, University of Bonn
>>>>> Katzenburgweg 5
>>>>> Phone: 0228732031
>>>>> 53115, Bonn,Germany.
>>>>>
>>>>>         [[alternative HTML version deleted]]
>>>>>
>>>>> _______________________________________________
>>>>> R-sig-mixed-models at r-project.org mailing list
>>>>> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>> --
>>>> The University of Edinburgh is a charitable body, registered in
>>>> Scotland, with registration number SC005336.
>>>>
>>>>
>>>>
>>>>
>>>
>>> --
>>> Dr. Boby Mathew
>>> INRES, University of Bonn
>>> Katzenburgweg 5
>>> Phone: 0228732031
>>> 53115, Bonn,Germany.
>>>
>>>
>>
>>
>> --
>> The University of Edinburgh is a charitable body, registered in
>> Scotland, with registration number SC005336.
>>
>>
>>
>
>
> --
> Dr. Boby Mathew
> INRES, University of Bonn
> Katzenburgweg 5
> Phone: 0228732031
> 53115, Bonn,Germany.
>



-- 
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.



More information about the R-sig-mixed-models mailing list