help > RE: Design matrix and contrast for Mixed ANOVA and post hoc simple main effects
Sep 9, 2018  06:09 PM | Andrew Zalesky
RE: Design matrix and contrast for Mixed ANOVA and post hoc simple main effects
Hi Taku,

Foremost, it might be worth considering a hypothesis about how connectivity will change across the 5 time points. For example, it might be hypothesized that time1 < time2 < time3 < time4 < time5, such that connectivity increases with time. Using this kind of ordered hypothesis will improve the statistical power of the design (which is currently very "unconstrained"), but it will not provide any power to detect alternative orderings across time. In other words, if you have a specific hypothesis, it would be worth formulating it into the design matrix because you have quite a few time points.

Regarding your design matrix, Columns 1-4 (time) include some rows that are populated with -1. It seems that all the cells with -1 in Columns 1-4 should be replaced with 0 (although I don't think this will have an affect on the final result). This will also impact Columns 5-8 (interaction effect). Perhaps try with the -1's replaced with 0's and test whether this makes a difference to the result.

Remember to include exchange blocks!

The F-contrast for the interaction would be [ 0 0 0 0 1 1 1 1 0 0 0 ....]. However, I think that the power to detect such an interaction will be low, and thus it may be wise to formulate the design matrix with respect to a specific hypothesis.

Alternatively, you could also test for an interaction at each specific time point using a t-test and the contrast [0 0 0 0 1 0 0 0 0 0 ...], [0 0 0 0 0 1 0 0 0 0 0], etc.

Regarding the main effects: for the main effect of group, you don't need multiple time points, and thus I suggest to first average across time before statistical inference, or not modelling time in the design matrix.

Regarding the main effect of time, the F-contrast would be [1 1 1 1 0 0 0 0 0 0....]. However, once again, I would suggest to formulate a specific hypothesis about how functional connectivity would change over time. This will improve statistical power.

Let me know if you have any questions,

Andrew

Originally posted by Takuji Hayashi:
Dear Prof. Zalesky,

I have 240 scans: 5 times from 48 participants. The data were divided into two groups (24 controls and 24 patients). I will perform a mixed (within-between) ANOVA to identify an interaction between them. If it is significant, I will further perform simple main effects at each time point (e.g., patient vs. control at time 1, patient vs. control at time 2, ...).

The data are aligned as:
control1-time1
control1-time2
control1-time3
control1-time4
control1-time5
control2-time1
.....
patient1-time1
patient1-time2
patient1-time3
patient1-time4
patient1-time5
patient2-time1
.....,

Then how do the design matrix and contrast look like?  To my understanding, the design matrix would be an attached file. Columns 1-4 indicates Time and Columns 5-8 indicates Interaction. Is it correct? Also, F contrast vector would be [0 0 0 0 1 1 1 1 0 0 0 , ... , 0] for interaction. Then how do you make the contrast vectors for the simple main effects?