[R] MGCV: Degrees of freedom of smooth terms
Gavin Simpson
Gavin.Simpson at uregina.ca
Thu Jul 25 18:26:25 CEST 2013
On Tue, 2013-07-23 at 11:16 +0200, Christoph Scherber wrote:
> Dear all,
>
> This is just a quick question regarding degrees of freedom in GAM
> models fit by MGCV (using select=T):
>
> Can I roughly interpret them as:
>
> 1 df: linear effect of x on y
> 2 df: approximately quadratic of x on y
> 3 df: approximately cubic effect of x on y?
Yes, approximately
> 1 df for a spatial term s(x,y): bilinear effect (?) or how would I call this?
A bilinear effect would have two df, no? In a linear regression z ~ x +
y would define a plane just like s(x, y) can and would use 2 df. 1 df
for the entire s(x,y) implies an additional penalty such that less than
1df is spent in the `x` or `y` dimensions of the spline.
> And what does "ref.df" in the summary output mean; is this the unpenalized degrees of freedom for
> each term?
IIRC, these are the dfs that are used in the tests reported. I am not
familiar enough with the details to comment more. If you turn on Select
= TRUE for example which adds an additional penalty then the ref.df can
be much larger than the edf values.
You might send an email to Simon Wood (or see if he picks up on this)
for a (far) more authoritative answer on this part of your question.
HTH
G
>
> Thank you very much for answering!
>
> Best wishes,
> Christoph
>
>
--
Gavin Simpson, PhD [t] +1 306 337 8863
Adjunct Professor, Department of Biology [f] +1 306 337 2410
Institute of Environmental Change & Society [e] gavin.simpson at uregina.ca
523 Research and Innovation Centre [tw] @ucfagls
University of Regina
Regina, SK S4S 0A2, Canada
More information about the R-help
mailing list