Re: [R] Plot with residuals in mgcv

2012-11-29 Thread Simon Wood
Hi Silje, Thanks for this. I guess RUTE is a numeric variable in this model and hence only has one associated random coefficient? This then causes a problem when calling predict.gam as part of processing 'residuals=T'. I've fixed the problem for the next release, but did you really want a

[R] Plot with residuals in mgcv

2012-11-28 Thread silje skår
Hi, I am using the mgcv package (version 1.7-22.) running the model works fine, but when I want to have a plot with residuals I get an error. fit29-gam(IV~s(G3)+s(V3)+factor(AAR)+s(D3)+s(RUTE,bs=re),data=subsf,gamma=1.4,method=ML) plot(fit29,residuals=T) Error in X[, first:last] %*%

Re: [R] Plot with residuals in mgcv

2012-11-28 Thread Peter Ehlers
On 2012-11-28 05:02, silje skår wrote: Hi, I am using the mgcv package (version 1.7-22.) running the model works fine, but when I want to have a plot with residuals I get an error. fit29-gam(IV~s(G3)+s(V3)+factor(AAR)+s(D3)+s(RUTE,bs=re),data=subsf,gamma=1.4,method=ML)

Re: [R] Plot with residuals in mgcv

2012-11-28 Thread William Dunlap
tibco.com -Original Message- From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On Behalf Of Peter Ehlers Sent: Wednesday, November 28, 2012 12:17 PM To: silje skår Cc: r-help@r-project.org Subject: Re: [R] Plot with residuals in mgcv On 2012-11-28 05:02