Estimation of variance components in random- and mixed-effects models
See also: https://stats.stackexchange.com/questions/37647/what-is-the-minimum-recommended-number-of-groups-for-a-random-effects-factor https://www.biorxiv.org/content/10.1101/2021.05.03.442487v2 (I should these links, and the blog post link, to the GLMM FAQ ...)
On 6/28/21 1:17 PM, Thierry Onkelinx wrote:
Another issue is that you have too few levels to fit "cohort" as a random effect. I wrote a blogpost on this a few years ago: https://www.muscardinus.be/2018/09/number-random-effect-levels/ <https://www.muscardinus.be/2018/09/number-random-effect-levels/> Best regards, ir. Thierry Onkelinx Statisticus / Statistician Vlaamse Overheid / Government of Flanders INSTITUUT VOOR NATUUR- EN BOSONDERZOEK / RESEARCH INSTITUTE FOR NATURE AND FOREST Team Biometrie & Kwaliteitszorg / Team Biometrics & Quality Assurance thierry.onkelinx at inbo.be <mailto:thierry.onkelinx at inbo.be> Havenlaan 88 bus 73, 1000 Brussel www.inbo.be <http://www.inbo.be> /////////////////////////////////////////////////////////////////////////////////////////// To call in the statistician after the experiment is done may be no more than asking him to perform a post-mortem examination: he may be able to say what the experiment died of. ~ Sir Ronald Aylmer Fisher The plural of anecdote is not data. ~ Roger Brinner The combination of some data and an aching desire for an answer does not ensure that a reasonable answer can be extracted from a given body of data. ~ John Tukey /////////////////////////////////////////////////////////////////////////////////////////// <https://www.inbo.be> Op ma 28 jun. 2021 om 16:31 schreef Ben Bolker <bbolker at gmail.com <mailto:bbolker at gmail.com>>: ? ?Are you using lme4? (I'm 99% sure you are, but it's good to be explicit.) ? ?Are all of your fixed predictors numeric (rather than factor/categorical) ? ? ?Note that a convergence warning is a *warning*, not an error: have you checked the troubleshooting steps in ?lme4::convergence (in particular, scaling and centering your predictor variables might help ...) ? ?cheers ? ? Ben Bolker On 6/28/21 10:17 AM, Amy Huang wrote:
> 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).
>? From the first model I am able to get the information, but from
the second
> 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
>
>? ? ? ?[[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-mixed-models at r-project.org
<mailto:R-sig-mixed-models at r-project.org> mailing list
>
_______________________________________________
R-sig-mixed-models at r-project.org
<mailto:R-sig-mixed-models at r-project.org> mailing list
https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
<https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models>