Hi all,

 

I would like to fit a gamm model of the form:

 

Y~X+X*f(z)

Where f is the smooth function and 

With random effects on X and on the intercept.

 

So, I try to write it like this:

 

gam.lme<- gamm(Y~ s(z, by=X) +X,  random=list(groups=pdDiag(~1+X))  )

 

but I get the error message :

 

Error in MEestimate(lmeSt, grps) : 

  Singularity in backsolve at level 0, block 1

 

When I simply fit a gam model using the formula above, then it works ok.

 

Is it possible to fit such a model with gamm?

 

 

Thanks a lot!


	[[alternative HTML version deleted]]

