Message-ID: <CAMu=eMBXb2OWFw2xNmq+0XSwFU1=m2bN5tCqjXT9U40EpLFV7g@mail.gmail.com>
Date: 2017-10-09T13:42:48Z
From: Mollie Brooks
Subject: spatial covariance structure in glmmTMB
In-Reply-To: <845771341.62814150.1507555332287.JavaMail.zimbra@sfu.ca>
Hi Alice,
Have you looked at the vignette on covariance structures? There's a section
on spatial correlations.
https://cran.r-project.org/web/packages/glmmTMB/vignettes/covstruct.html
cheers,
Mollie
On Mon, Oct 9, 2017 at 3:22 PM, Alice Domalik <adomalik at sfu.ca> wrote:
> Dear list,
>
> I am fitting mixed effects models using the package glmmTMB to investigate
> habitat use.
> My current model has the form m1<-glmmTMB(count~waterdepth + temperature +
> chl.conc + (1|individual), family=list(family="truncated_nbinom1",
> link="log"), data=mydata)
> I would like to add a spatial covariance structure based on geographic
> coordinates (mydata$x and mydata$y).
> However, I do not know how to modify my model formula to include a spatial
> covariance structure. Does anyone have example code to show how this is
> done?
>
> Any help would be much appreciated!
>
>
>
> [[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-mixed-models at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>
[[alternative HTML version deleted]]