[FieldTrip] Design Matrix for 2 by 2 interaction in cluster-based permutation
Lee, Kyoung Eun
klee773 at gatech.edu
Tue Sep 15 06:30:35 CEST 2020
Hello FieldTrip users,
I want to test an interaction effect using cluster-based permutation test.
In my study, I have a between-subject conditions (older adults vs. younger adults) and a within-subject conditions(Hit vs. Miss). Therefore, it is 2 x 2 design.
I've tried to follow this tutorial (http://www.fieldtriptoolbox.org/faq/how_can_i_test_an_interaction_effect_using_cluster-based_permutation_tests/), but it gave an error.
I think my design matrix might be the problem.
First, I made two difference data structure like : Older adults (Hit-Miss difference) & Younger adults (Hit-Miss difference).
And let's say I have 8 older adults and 12 younger adults. So I made my design matrix as : [1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 2 2 ]
And set the cfg.uvar = 1; cfg.statistic = 'indepsamplesT';
However, when I ran it, it gave me an error as below:
Error using ft_notification (line 314)
A within-units shuffling requires a at least one unit variable and at least one independent variable
Error in ft_error (line 39)
ft_notification(varargin{:});
Error in resampledesign (line 168)
ft_error('A within-units shuffling requires a at least one unit variable and at least one independent variable');
Error in ft_statistics_montecarlo (line 213)
resample = resampledesign(cfg, design);
Error in ft_freqstatistics (line 194)
[stat, cfg] = statmethod(cfg, dat, design);
In this case, how can I get a result?
Thank you for your help in advance.
Best,
Cay
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20200915/1a924964/attachment.htm>
More information about the fieldtrip
mailing list