[R] no convergence using lme

From: Margaret Gardiner-Garden <m.gardiner-garden_at_garvan.org.au>
Date: Wed 15 Feb 2006 - 13:04:21 EST


Hi. I was wondering if anyone might have some suggestions about how I can overcome a problem of "iteration limit reached without convergence" when fitting a mixed effects model.  

In this study:

Outcome is a measure of heart action

Age is continuous (in weeks)

Gender is Male or Female (0 or 1)

Genotype is Wild type or knockout (0 or 1)

Animal is the Animal ID as a factor

Gender.Age is Gender*Age

Genotype.Age is Genotype*Age

Gender.Genotype.Age is Gender*Genotype*Age  

If I have the intercept (but not the slope) as a random effect the fit converges OK

fit1 <- lme(Outcome~Age + Gender + Genotype + Gender.Age + Genotype.Age + Gender.Genotype.Age,

                  random=~1|Animal, data=VC)

 

 

If I have the slope (but not the intercept) as a random factor it converges OK

fit2 <- lme(LVDD~Age + Gender + Genotype + Gender.Age + Genotype.Age
+Gender.Genotype.Age,

                  random=~Age-1|Animal, data=VC)

 

 

If I have both slope and intercept as random factors it won't converge

fit3 <- lme(LVDD~Age + Gender + Genotype + Gender.Age + Genotype.Age + Gender.Genotype.Age,

                  random=~ Age|Animal, data=VC)

Gives error:

Error in lme.formula(LVDD ~ Age + Gender + Genotype + Gender.Age + Genotype.Age + :

      iteration limit reached without convergence (9)      

If I try to increase the number of iterations (even to 1000) by increasing maxIter it still doesn't converge  

fit <- lme(LVDD~Age + Gender + Genotype + Gender.Age + Genotype.Age + Gender.Genotype.Age,

+ random=~ Age|Animal, data=VC, control=list(maxIter=1000,
msMaxIter=1000, niterEM=1000))  

NB. I changed maxIter value in isolation as well as together with two other controls with "iter" in their name (as shown above) just to be sure ( as I don't understand how the actual iterative fitting of the model works mathematically)  

I was wondering if anyone knew if there was anything else in the control values I should try changing.

Below are the defaults..

lmeControl

function (maxIter = 50, msMaxIter = 50, tolerance = 1e-06, niterEM = 25,

    msTol = 1e-07, msScale = lmeScale, msVerbose = FALSE, returnObject = FALSE,    gradHess = TRUE, apVar = TRUE, .relStep = (.Machine$double.eps)^(1/3),

   minAbsParApVar = 0.05, nlmStepMax = 100, optimMethod = "BFGS",

    natural = TRUE)  

I was reading on the R listserve that lmer from the lme4 package may be preferable to lme (for convergence problems) but lmer seems to need you to put in starting values and I'm not sure how to go about chosing them. I was wondering if anyone had experience with lmer that might help me with this?  

Thanks again for any advice you can provide.  

Regards

Marg    

Dr Margaret Gardiner-Garden

Garvan Institute of Medical Research

384 Victoria Street

Darlinghurst Sydney

NSW 2010 Australia  

Phone: 61 2 9295 8348

Fax: 61 2 9295 8321    

        [[alternative HTML version deleted]]



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Wed Feb 15 13:16:02 2006

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:42:31 EST