[R-sig-ME] In mer_finalize(ans) : gr cannot be computed at initial par (65)
Douglas Bates
bates at stat.wisc.edu
Tue Jun 22 17:34:10 CEST 2010
Would it be possible to make the data available so we could check on
the models being fit?
On Tue, Jun 22, 2010 at 10:14 AM, Chris Mcowen <cm744 at st-andrews.ac.uk> wrote:
> Dear R List -
>
> I am trying to do a relatively simple GLMM but am having a problem.
>
> My data is categorical but converted to numeric form in excel ( i.e a=1, b=2 etc) my response is binary and i have two random terms - FAMILY and ORDER.
>
> I have been running the model fine calling this -
>
> model2 <- lmer(THREAT~1+(1|ORDER/FAMILY) + BREEDING_SYSTEM*LIFE_FORM + WOODY_NONWOODY, family=binomial)
>
> Fixed effects:
> Estimate Std. Error z value Pr(>|z|)
> (Intercept) 2.62364 1.41554 1.853 0.06382 .
> BREEDING_SYSTEM -1.24256 0.47227 -2.631 0.00851 **
> LIFE_FORM -0.64368 0.29026 -2.218 0.02659 *
> WOODY_NONWOODY 0.51817 0.19548 2.651 0.00803 **
> BREEDING_SYSTEM:LIFE_FORM 0.22289 0.09842 2.265 0.02353 *
How many different levels of BREEDING_SYSTEM and LIFE_FORM do you
have? I assume that WOODY_NONWOODY is a binary variable. If the
others have more than two possible levels, and your saying that Excel
stored them in numeric form (a = 1, b = 2, etc.) leads me to believe
that there may be more than two, then you are not fitting an
appropriate model.
> However i want to know what type of life form, breeding system etc is significant so i called -
>
> woodynonwoody <- as.factor(WOODY_NONWOODY)
> habit <- as.factor(HABIT)
> breedingsystem <- as.factor(BREEDING_SYSTEM)
>
> model3 <- lmer(THREAT~1+(1|ORDER/FAMILY) + breedingsystem + woodynonwoody*habit, family=binomial)
> Warning message:
> In mer_finalize(ans) : gr cannot be computed at initial par (65)
>
> model3
> Error in asMethod(object) : matrix is not symmetric [1,2]
>
> Interestingly when i try the above call without the interaction term it works
Yes. Generalized linear models and generalized linear mixed models
can't support a large number of possibly redundant coefficients. You
need to be careful of your model-building strategy. Starting from the
most complex model possible and using backward elimination doesn't
always work.
>
> Any help would be greatly appreciated
>
> Chris
>
>
>> sessionInfo()
> R version 2.11.1 (2010-05-31)
> i386-apple-darwin9.8.0
>
> locale:
> [1] en_GB.UTF-8/en_GB.UTF-8/C/C/en_GB.UTF-8/en_GB.UTF-8
>
> attached base packages:
> [1] stats graphics grDevices utils datasets methods base
>
> other attached packages:
> [1] perturb_2.03 lme4_0.999375-34 Matrix_0.999375-40 lattice_0.18-8
>
> loaded via a namespace (and not attached):
> [1] grid_2.11.1 nlme_3.1-96 stats4_2.11.1 tools_2.11.1
>
>
> Chris Mcowen
> PhD Student
>
> Room 15
> Sir Harold Mitchell Building
> University of St Andrews
> St Andrews
> Fife
> KY16 9TH
> UK
> Phone 01334 463381
>
>
> [[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-mixed-models at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>
More information about the R-sig-mixed-models
mailing list