[R-sig-ME] Random effects in GAMs

Philippi, Tom tom_philippi at nps.gov
Fri Feb 12 20:40:21 CET 2016

Without further information on your data generating process and what
structure you are trying to capture with your model, we don't know what
your random effects are accounting for. For instance, my frequent use case
is GAM for smoothing across time, and sites as random effects, which
requires mgcv::gamm or gamm4:gamm4 (the first method in your linked page)
instead of gam() with s(...,bs='re').   I don't think that anyone can give
you helpful answers without that further information.

I highly recommend Simon Wood's book "Generalized Additive Models".  It
starts with clear explanations of linear models and generalized linear
models, builds through gams, and ends with a chapter on mixed models and
gamms.  I find it to be a valuable reference for LM, GLM, GAM, and GAMM,
all in a single book.

Tom 2

On Fri, Feb 12, 2016 at 10:58 AM, Julian Chen <power.julian.chen at gmail.com>

> I am now trying to use random effects in GAMs developed by Professor Simon
> Wood. Prof Wood uses  s(...,bs="re") to account for the random effects.
> Random intercepts models or random slopes models are two different types of
> mixed linear models or general random effects model (Cameron and Trivedi,
> 2005). I wonder if the Wood's method includes both random intercepts and
> random slopes. Based on my understanding, this method does? Anyone can help
> me clarify this method? The following is the link of Random effects in GAM
> developed by Prof Wood.
> https://stat.ethz.ch/R-manual/R-devel/library/mgcv/html/random.effects.html
> --
> Life is nothing but a dream,
>      and if we are artists,
> then we can create our life with Love,
>      and our dream becomes
>        a masterpiece of art.
>         [[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]]

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