[R-sig-ME] glmm with correlated residuals

Jarrod Hadfield j.hadfield at ed.ac.uk
Thu Dec 20 23:02:23 CET 2012


Hi Emilio,

asreml will fit such a model but the PQL method it uses for  
approximating the likelihood can give dodgy results in some cases. For  
Poisson data, particularly if it has high mean, it might be OK though.  
It is fast enough that you can check the degree of bias using  
simulation.

You can fit spatial simultaneous autoregressive lag models in MCMCglmm  
but only for Gaussian data. It would be very difficult for me to  
implement these for  non-Gaussian data.

AR(1) models with nugget effect could be fitted, but only if the  
correlation parameter is known. The inverse of the correlation matrix  
could then be passed to ginverse and the scale estimated, but this is  
not that much use I guess.


Cheers,

Jarrod





Quoting Ben Bolker <bbolker at gmail.com> on Thu, 20 Dec 2012 20:53:50  
+0000 (UTC):

> Joshua Wiley <jwiley.psych at ...> writes:
>
>>
>> Hi Emilio,
>>
>> I would suggest doing it in MCMCglmm.  It can handle residual
>> structures too.  This is a nice starting guide:
>> http://cran.r-project.org/web/packages/MCMCglmm/vignettes/CourseNotes.pdf
>>
>> Cheers,
>>
>> Josh
>
>   Josh, are you sure?  I don't find "autoreg" anywhere in the course notes.
> I don't personally know of an easy way to do this other than using INLA
> (which I haven't tried much); glmmPQL (easy but perhaps dicey depending
> on the circumstances, and sometimes hard to figure out whether it's
> fitting a well-defined model); or hand-coding in WinBUGS/JAGS/Stan or
> AD Model Builder ...  You could also give up on Poisson-ness (you said
> there was heterogeneity of variance -- not quite sure what that means
> in this context?) and fit a GLS model with appropriate variance
> structure (using gls() with weights= and correlation= arguments set).
>
>   I'd love to hear other answers.
>
>   Ben
>
>
>>
>> On Thu, Dec 20, 2012 at 8:37 AM, Emilio A. Laca <ealaca at ...> wrote:
>> > Fellow R users,
>
>> > what package would you recommend for fitting a poisson glmm with
>     one random effect and residuals that are correlated (most likely
>     AR(1)) and have heterogeneity of variance?  I have successfully
>     fitted the model without addressing the structured residuals in
>     MCMCglmm.  I would appreciate it very much if you could point me
>     in the direction of an example.
>
>> > Emilio A. Laca, Professor
>
>  [snip]
>
> _______________________________________________
> 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.



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