Dear Helmut,
I like to use the Flexible factorial with the 4 columns G1T1 G1T2 G2T1 G2T2 to test the following contrasts:
1) T2 > T1 (averaged across group). Can I use [-1 1 -1 1] for this?
2) (G1T2-G1T1) > (G2T2-G2T1). What for a contrast do I need for this? [-1 1 1 -1]?
Many thanks again for your great help
André
________________________________________
Von: H. Nebl [[log in to unmask]]
Gesendet: Dienstag, 22. September 2015 15:11
An: [log in to unmask]; André Schmidt
Betreff: Re: repeated measures ANOVA
Dear André
To have the correct error terms go with two separate models as follows.
1) one Flexible factorial to test for main effect "Time" and interaction "Group x Time"
Settings: factor "Group" = unequal var., independence yes, "Time" = equal var. (possibly also unequal), independence no, "Subject" = equal var., independence yes, then select the corresponding two con images (or e.g. s(m)wc1 in case of VBM / GM files) for each of the subjects. For "Main effects & Interactions" go with "Interaction" and factor numbers [1 2] and one "Main effect" with factor number 3. The terms "Interaction" and "Main effect" are confusing, but this way you obtain four columns G1T1 G1T2 G2T1 G2T2 that code the two time points separately for the two groups plus n subjects' columns, which should be* sufficient. To test for main effect "Time" go with [0.5 -0.5 0.5 -0.5 ...], to test for the interaction "Group x Time" go with [1 -1 -1 1 ...], also see the attached file.
* If you browse the archives you might also notice some messages that during "Main effects & Interactions", you should include three "Main effects" (one for 1, 2, 3 each) plus the interaction [1 2]. The design matrix would then consist of G1 G2 T1 T2 G1T1 G1T2 G2T1 G2T2 plus n subjects' columns, the corresponding vectors would be [0 0 1 -1 0.5 -0.5 0.5 -0.5 ...] for main effect "Time" and [0 0 0 0 1 -1 -1 1 ...] for the interaction. This should lead to identical results though (please double-check yourself), as it's just different coding & SPM accounts for that. In fact, one could think of another design matrix with a column "constant" (1 everywhere), another for main effect "group" (coding 1 for G1 and -1 for G2), another for time (1 for T1 and -1 for T2) and finally, one for the interaction (with 1 for G1T1 and G2T2 and -1 for G1T2 and G2T1) plus the subjects' columns.
2) one two-sample t-test to test for main effect "group" based on contrast images that average across the two time points
For that purpose set up a corresponding contrast vector on single-subject level (in the simplest case something like [0.5 0.5 ...]), in case of VBM / GM files generate a mean image with Imcalc with mean(X) from the two s(m)wc1 files. To test for main effect "Group" go with [1 -1] within the two-sample t-test.
In case of VBM, to make sure you're looking at the same selection of voxels in the two-sample t-test go with the mask.nii obtained from the Flexible factorial and specify this as an explicit mask for the two-sample t-test instead of the threshold masking \ absolute threshold.
Best
Helmut
|