[R] Random effects in gam (mgcv 1.7-19)

Simon Wood s.wood at bath.ac.uk
Fri Aug 24 14:42:21 CEST 2012


Silje,

Thanks for reporting this. Should be fixed for version 1.7-20 (but 
please let me know if not!)

best,
Simon

On 14/08/12 12:08, silje skår wrote:
> Hi,
>
> I am using the gam function in the mgcv package, I have random effects in
> my model (bs="re") this has worked fine, but after I updated the mgcv
> package to version 1.7-19 I recive an error message when I run the model.
>
>>
> fit1<-gam(IV~s(RUTE,bs="re")+s(T13)+s(H40)+factor(AAR)+s(V3)+s(G1)+s(H1)+s(V1)+factor(LEDD),data=data5,method="ML")
>> summary.gam(fit1)
> Error in mroot(Ve[ind, ind]) : Supplied matrix not symmetric
>
> This same model worked fine before I updated the mgcv package, does anyone
> know why I now get the error message?
>
> Another question I have is if anyone knows how I can compare two gam models
> that includes "re" terms? As far as I understand an anova is not the best
> way when I have "re" terms.
>
> Best regards
> Silje Skår
>
> 	[[alternative HTML version deleted]]
>
>
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>


-- 
Simon Wood, Mathematical Science, University of Bath BA2 7AY UK
+44 (0)1225 386603               http://people.bath.ac.uk/sw283




More information about the R-help mailing list