[FieldTrip] Permutation test design matrix for grand-averaged ERPs
m.manahova at gmail.com
Tue Oct 23 14:55:30 CEST 2018
You mention that you're using indepsamplesT, so are you doing a test
between groups (comparing two different groups) or within participants
(comparing the same participants in two conditions)? If it's the latter,
then I'd suggest using depsamplesT.
I am pasting below a good way to define your design matrix. This works well
for a within-participant comparison. You'll need to adapt it if yours is
indeed between groups. See the comments for the explanation.
Nsub = 29;
cfg.design(1,1:2*Nsub) = [ones(1,Nsub) 2*ones(1,Nsub)];
cfg.design(2,1:2*Nsub) = [1:Nsub 1:Nsub];
cfg.ivar = 1; % the 1st row in cfg.design contains the
cfg.uvar = 2; % the 2nd row in cfg.design contains the
A possible problem is if you've computed grand averages and haven't used
cfg.keepindividual = 'yes'. If that's the case, I'd suggest keeping the
individual participants' data when calling ft_timelockgrandaverage. And
then using the correct design matrix.
I hope this helps! Let us know if it still doesn't work.
All the best,
On Tue, Oct 23, 2018 at 2:35 PM Kate Stone <katemsto at gmail.com> wrote:
> Hi all,
> I've been following the tutorial here to do a time-locked perm test on ERP
> data: www.fieldtriptoolbox.org/tutorial/cluster_permutation_timelock
> I have computed grand averages for my two conditions and am using
> indepsamplesT with ft_timelockstatistics(cfg, GA_1, GA_2).
> But what should the design matrix be? The example in the tutorial doesn't
> apply as I am using grand averages and the reference for
> ft_timelockstatistics doesn't mention the design matrix, although it is
> definitely required. I have tried design = [1,2], but this doesn't seem to
> give sensible results.
> Thanks in advance,
> fieldtrip mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the fieldtrip