GLMER, longitudinal data, random factor, binomial

Asked

Viewed 97 times

2

I’m using the function glmer package lme4. My answer is binomial.

I have 5 schools, with approximately 100 teachers, and a teacher does not work in more than one school, I have 5 longitudinal information for each teacher.

My question is whether I use:

(1|escola/prof) ou (1 | escola) + (1 | prof) ou (1|prof/escol).

Or I’m thinking wrong and it’s another way?

  • 1

    Dear Cleber, I’m voting to close your question because it’s not about programming. I believe you have read the table on page 6 of this link: https://cran.r-project.org/web/packages/lme4/vignettes/lmer.pdf. which explains what each of these commands means. From then on, the problem becomes statistical, which is beyond the scope of the site. My guess is that any one of the three will be very similar since no teacher teaches at two schools. However, I believe that the third does not make much sense (looking through the hierarchy).

  • 1

    My suggestion is to use the first: each school has a random intercept and each teacher has a random variation within the school.

  • 1

    Thank you for the comment and the link.

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.