Tuesday, November 24, 2009

lme - lmer mixed models

Dear Kim,

first of all, please use lmer() from library "lme4", instead of lme. I think that is currently better maintained and developed than the "nlme" library.
The model you suggest is a random regression per individual (obs_nr)?
The syntax would become


It should work provided there are several observations of MiWi for each level of obs_nr, which seems to be the case given your explanation of the data.

Cheers, Tom

Mixed effects models


I am currently trying the exercises of Crawley on mixed effects model (ex. 7). I remade the example on page 33/34 and am currently trying tho do this analysis with my own data. I have a response variable (size=MiWi), measured at different dates (date) on the same individual (obs_nr = random variable). Further more I have insects species (ins_spec) and host species (host_spec) as fixed variables. When I run it I get the error message:

cocon_mixed<-lme(fixed=MiWi~host_spec*ins_spec,data=cocon_nash,random=~date|obs_nr) Error in lme.formula(fixed = MiWi ~ host_spec * ins_spec, data = cocon_nash, :
nlminb problem, convergence error code = 1
message = iteration limit reached without convergence (9)

What is going wrong?


Thursday, November 12, 2009

Course GLM Groningen

I just returned from the glm course in Groningen. I will invite all participants to this blog in the coming days. Meanwhile, I already add a link to a page with several simple scripts:


As you will see, these files haven't been updated at all.
If things in them have become obsolete, please let me know.

Cheers, Tom