Skip to content
Prev 19350 / 20628 Next

Estimation of variance components in random- and mixed-effects models

Dear all,

I am examining maternal effects, and my data have three hierarchy levels:
clutches of the same female, females, and cohorts. My explanatory variables
are at the female level (female length, age) and at the cohort level
(temperature).

I would like to estimate the variance components of each hierarchy level
(i.e. relative amount of variance at each level) and then to find out which
factors (female length, age, temperature) explain most of the variance. For
these, I have two models:
    offspring trait ~ 1 + (1 | cohort/female/clutch)
    offspring trait ~ temperature + female length + age + (1 |
cohort/female/clutch)

The major problem is that I only have 3 cohorts (and so 3 temperatures).
one there is an error message: "Model failed to converge with 1 negative
eigenvalue: -2.0e+01". The error pops up probably because I have both
temperature (fixed) and cohort (random) included. Is my approach correct?
And is there a way to fix this error?

Thank you so much for your time.

Best regards,
Amy Huang