[FieldTrip] Question on coherence stats at sensor level
David Pedrosa
david.pedrosa at ndcn.ox.ac.uk
Tue Mar 1 16:21:36 CET 2016
Dear list,
I running analyses on the sensor level with EMG-EEG coherence data and I ran into some problems. Basically my intention is to compare the corticomuscular coherence at rest versus during an activation task. For that, according to some older posts and literature, I computed the Z-transformed coherence (after using ft_connectivityanalyses, I manually transformed the cohspctrm data with respect to the dof) which I want to test with a permutation test. Now, when it comes to computing the stats, it gives me the error >> Function 'diff' is not supported for class 'struct'. << Would it be more reasonable using another function? Or does anyone have an idea where my problem could be or what I should do instead?
Here's the used code I use:
%% for loop normalizing coherence manually and creating 0-coherence data...
coh_diff{1,1} = coh_diff_condition{1,1}.cohspctrm = (atanh(x1) - ...
coh_diff_null{1,1}.cohspctrm(:) = 0;
cfg = [];
cfg.channel = {'EEG' 'xEDC'};
cfg.parameter = 'cohspctrm';
cfg.method = 'montecarlo';
cfg.statistic = 'diff';
cfg.tail = 0;
cfg.clustertail = 0;
cfg.alpha = .025;
cfg.numrandomization = 500;
cfgl = [];
cfgl.layout = 'brainamp.sfp';
cfg.layout = ft_prepare_layout(cfgl);
cfg.computestat = 'yes';
cfg.correctm = 'cluster';
cfg.clusteralpha = .05;
cfg.clusterstatistic = 'maxsum';
cfg.minnbchan = 2;
cfgn = [];
cfgn.method = 'distance';
cfgn.neighbourdist = 40; %in mm
cfg.neighbours = ft_prepare_neighbours(cfgn,data_epoched_wo);
design = zeros( 2,2*numel(coh_diff));
design(1,:) = [1:numel(coh_diff), 1:numel(coh_diff_null)];
design(2,1:numel(coh_diff)) = 1;
design(2,numel(coh_diff)+1:numel(coh_diff)+numel(coh_diff_null)) = 2;
cfg.design = design;
cfg.ivar = 1;
cfg.uvar = 2;
[stat] = ft_freqstatistics(cfg, coh_diff{1,1}, coh_diff{1,2}, ..., coh_diff_null{1,12};
Thanks for your help.
Best,
David
________________________________
Dr. David Pedrosa
Clinical Research Fellow
Medical Research Council Brain Network Dynamics Unit at the University of Oxford
Nuffield Department of Clinical Neurosciences
University of Oxford
Level 6, West Wing
John Radcliffe Hospital, OX3 9DU
Tel: +44 (0)1865 572490
E-Mail: david.pedrosa at ndcn.ox.ac.uk
http://www.mrcbndu.ox.ac.uk/<https://owa.nexus.ox.ac.uk/owa/redir.aspx?C=E40BwPuNq0uXQGSOPDW39AmtYlwBR9IIjsI0PRu9uuTE46jeZnqjmG6XP02rBAUiF1EnCJtn3UU.&URL=http%3a%2f%2fwww.mrcbndu.ox.ac.uk%2f>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160301/b209b851/attachment-0001.html>
More information about the fieldtrip
mailing list