[Eeglablist] newtimef data input
Gianluca Finotti
g.finotti at unibo.it
Fri Jul 29 06:16:27 PDT 2022
Hello everyone,
I have an experiment with 8 conditions and I have calculated the grand average for each subject in each condition.
So, for instance, in condition 1 I have a data matrix which is 64x2350x37 (channels X timepoints X subjects).
For each subject, the trials in that condition are already averaged.
I want to calculate the ERSP in each condition and compare some of the conditions, so, I have tried something like this:
[ersp,itc,powbase,times,freqs,erspboot,itcboot,tfdata] = newtimef({Condition1, Condition2}, size(Condition1, 2), ...
[grand(1).times(1) grand(1).times(end)], ...
grand(1).srate, [3 8], 'plotphase', 'off', 'baseline', timeFreqBaseline, ...
'freqs', [4 40], 'freqscale', 'log', ...
'nfreqs', [37], 'vert', vertLineNewTimeEf, 'erspmax', 3, ...
'title', {'Condition1' 'Condition2'}, 'alpha' , 0.01);
According to the documentation, the data argument must be:
Single-channel data vector (1,frames*ntrials), else
2-D array (frames,trials) or 3-D array (1,frames,trials).
My question is: can I consider the participants as trials or is this theoretically wrong?
Should I instead calculate the ERSP on each participant and each channel before averaging the trials?
So, I would have something like:
data = channel 1, participant 1, 40 trials
Newtimef (data....)
Then repeat for all other channels and participants?
The problem is that, if I follow this second approach, then I can't compare two conditions directly...
I hope I was clear enough.
Thank you in advance,
Gianluca
More information about the eeglablist
mailing list