help > Repeated Measures ANOVA
Showing 1-4 of 4 posts
Display:
Results per page:
Jun 21, 2023  05:06 AM | Emily Robinson
Repeated Measures ANOVA

Hi, 


I'm attempting to create a design matrix and contrasts, for a two-way repeated measures ANOVA. 


I have two groups (cannabis users and controls), and scans at two time points (age 14  (time 1) and age 19 (time 2)).


I'm wanting to look at the main effects of group, and time, and the group by time interaction on FA. I've set up a matrix (attached) for the time and group by time interaction. I'm also planning on subtracting the time 1 and time 2 images from each other, and creating a seperate matrix for a two group mean comparison to identify the effect of group. 


I wanted to ask if this approach, and the matrix and the contrasts I'd set out for the main effect of time and group*time interaction, were correct? 


Also, how I would go about adding age (mean centered) and sex as covariates? 


Warmly,


Emily 

Jun 21, 2023  07:06 AM | Andrew Zalesky
RE: Repeated Measures ANOVA

Hi Emily,


your current design matrix will probably give a "rank deficient" warning. You will need to remove the "Group" column and things should then work ok. Note that and individual's group remains the same between time points 1 and 2, and thus it is not necessary to model Group (other than using it to help form the interaction column). 


If you would like to investigate the effect of group (rather than a group x time interaction), you could average FA across the two time points for each subject and use a t-test. Alternatively, you could run a t-test between group separately for each time point. A repeated measures design is not needed to assess the main effect of group. 


Your contrasts are correct. 


Because this is a repeated measues design, there is no need to add sex as a covariate because sex presumably remains the same between the two time points.


I hope that helps! I'm happy to provide more detailed advice if necessary. Just let me know... 


andrew 


 


Originally posted by Emily Robinson:



Hi, 


I'm attempting to create a design matrix and contrasts, for a two-way repeated measures ANOVA. 


I have two groups (cannabis users and controls), and scans at two time points (age 14  (time 1) and age 19 (time 2)).


I'm wanting to look at the main effects of group, and time, and the group by time interaction on FA. I've set up a matrix (attached) for the time and group by time interaction. I'm also planning on subtracting the time 1 and time 2 images from each other, and creating a seperate matrix for a two group mean comparison to identify the effect of group. 


I wanted to ask if this approach, and the matrix and the contrasts I'd set out for the main effect of time and group*time interaction, were correct? 


Also, how I would go about adding age (mean centered) and sex as covariates? 


Warmly,


Emily 



 

Jul 5, 2023  08:07 AM | Emily Robinson
RE: Repeated Measures ANOVA

Hi Andrew, 


Thank you so much for your help, it really made completing the design matrix a lot easier.


I had one question, I'm trying to include age and sex as covariates for the age*time interaction, but I keep getting a rank deficiency error. This doesn't happen when I try to control for age, so is it possible to control for sex (which I tried both mean centred and not), or say site (which also doesn't change over time), within the interaction effect, without a rank deficiency? 


Warmly, 


Emily 

Jul 5, 2023  11:07 AM | Andrew Zalesky
RE: Repeated Measures ANOVA

Hi Emily, 


for a within-subject design, controlling for sex is not really necessary. This is because a subject's sex presumably remains constant between timepoints 1 and 2, and therefore it is inhernetly controlled. To investigate the imapct of sex, a longitudinal design is not needed and you could test for sex effects at each time point independently. 


Andrew


 


Originally posted by Emily Robinson:



Hi Andrew, 


Thank you so much for your help, it really made completing the design matrix a lot easier.


I had one question, I'm trying to include age and sex as covariates for the age*time interaction, but I keep getting a rank deficiency error. This doesn't happen when I try to control for age, so is it possible to control for sex (which I tried both mean centred and not), or say site (which also doesn't change over time), within the interaction effect, without a rank deficiency? 


Warmly, 


Emily