0
$\begingroup$

I have data from two groups (divisions) of participants that consider attention lapses. The question is, first, do the number of attention lapses change over the two testings, and second, do the divisions differ in attention lapses. I tested this applying this code lmer(attention_lapses ~ testing_session + division + (1|id), data=data) And for the post hoc group comparison in each testing session emmeans::emmeans(my_model, pairwise ~ division | testing_session) As you can see from the figure , the group variances do differ quite some. Then, are my results correct when lmer assumes equal variances between the groups (or does it)? enter image description here In addition, I applied lme to model different group variances, and based on ANOVA the second model (b) fit was better.

a <- lme(over_500ms ~ testing_session + division, data = PVT, random = ~1|id)
b <- lme(over_500ms ~ mittauskerta + division, 
     random = list(id = pdDiag(form = ~ division)),
     weights = varIdent(form = ~1 | division),
     data = PVT)

The problem is that I do not quite understand what the model b specification implies. Therefore, can I trust the results of the first lmer-model? In each case, the results are similar tho. Significant group differences on both testing sessions and no within-group change in attention lapses over the testing sessions.

$\endgroup$
3
  • $\begingroup$ I wonder if things would be somewhat more stable if you used a square-root transformation. I still think you'd get unequal variances, but it'd be somewhat less severe, you'd have better symmetry, and the outliers in the baseline measurements wouldn't be quite as bad. Did you expect these two groups of subjects to differ in variability? It's pretty remarkable. $\endgroup$
    – Russ Lenth
    Commented Feb 1, 2022 at 4:04
  • $\begingroup$ Hey @RussLenth, yes, the group with the large variation in attention lapses (reaction time over 500ms ) is a sleep-deprived group, and another one had normal overnight sleep. They did the post-test after prolonged stressful activities. Then it is not surprising that the more awake participants show very little variation in reaction times, whereas within the sleep-deprived, some are more vulnerable to sleep loss. Somehow I do not feel quite right about transforming the data either. $\endgroup$
    – timothy
    Commented Feb 1, 2022 at 7:03
  • $\begingroup$ A square-root transformation is pretty common practice when using models that assume normal responses to fit count data. $\endgroup$
    – Russ Lenth
    Commented Feb 2, 2022 at 2:10

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.