See inline comments below.


On Mon, Jul 20, 2015 at 2:13 PM, nswa66 <[log in to unmask]> wrote:
Dear SPMers,

I am looking for an option for doing ANOVA with repeated measures for 2-level stats for a longitudinal data. I first did longitudinal processing with VBM8,  after that,  I defined the stats 
(as suggested on the VBM8 manual, see attached).  I have two groups, two time points. So in the "Flexible Factorial", I specified the scans and the conditions as [1 1; 1 2]' (for the data of the two time points from the subjects in the first group), or [2 2; 1 2]' (for the data of the two time points from the subjects in the second group);  then I defined: Main effect, factor number -->1, interaction, factor numbers -->2 3.   But after this is done, how shall I define the contrast? I am mostly interested in the interaction. Should it be F-stat, 1 1 -1? 

F1L1_F2L1 F1L1_F2L2 F1L2_F2L1 F1L2_F2L2 Subjects

If this is the order of the columns, then the interaction would be:
[1 -1 -1 1 zeros(1,N)] where N is the number of subjects

 

And how shall I define the contrast to know the difference between the two groups in the amount of change between the two time points ?  (in particular, I need to know which group is larger or smaller on every voxel, but it seems the output normally only tells you which voxels are significant, but do not tell you the direction of  one group being higher or lower. How can I know the directions of the difference?  

If you use a t-test, then you will get the direction of which group has a larger change over time. You can also extract the contrast values for two additional contrasts:
1 -1 0 0 zeros(1,N) and 0 0 1 -1 zeros(1,N) to get the change in each group. For simplicity of plotting, you could use an F-test:
[1 -1 0 0 zeros(1,N); 0 0 1 -1 zeros(1,N)]

or 

[ 1 0 0 0 ones(1,N)/N; 0 1 0 0 ones(1,N)/N; 0 0 1 0 ones(1,N)/N; 0 0 0 1 ones(1,N)/N]

to plot the contrast for each individual timepoint and group pairing.

 

Also I hope to know, is this procedure described above, if done correctly, implementation of  "ANOVA with repeated measures"?  (because ANOVA with repeated measures, (which seems somewhat different from a regular 2x2 ANOVA), is what I am supposed to do for the longitudinal study).

Yes. You need to use the versions for repeated measures.
 

Thank you very much!!!

-Diane