Dear colleagues,
I am analizing pupil size data using mixed model analysis in R. I use lme - package nlme. However, I am encountering serious problems of heteroscedasticity (see attached image) and violation of normality assumption.
Do you have any suggestions how to solve this problem?
I would like to test whether active stimulation (vs. sham; Stimulation type) increases pupil size over time (before stimulation vs. end stimulation; Time). We employed a between subject design.
I adopted the following strategies that did not solve the problem:
1. transformed the outcome - log().
2. modelled the covariance-variance matrix following the instructions in this page https://rpsychologist.com/r-guide-longitudinal-lme-lmer#heteroscedasticity-at-level-1 .
Here the models:
Time (0 vs . 1)
Stimulation (0 vs 1)
Tonic_PS = pupil size
ID = participant ID
model.1