[Eeglablist] questions about PSD, FFT and baseline corrections for my epochs.
Arnaud Delorme
adelorme at ucsd.edu
Thu Oct 31 16:02:53 PDT 2024
> I have questions about PSD, FFT and baseline corrections for my epochs.
>
> I am looking at the overall PSD after the stimulus is presented to analyze the time-on-task effect later.
>
> I ran the following code:
> ------------------
> [STUDY, ALLEEG]= std_precomp(STUDY, ALLEEG, 'channels' ,'interp','on','recompute','on','erp','on','erpparams',{'rmbase',[-300 -1] }, 'spec' , 'on', 'specparams', {'specmode','psd','logtrials','off', 'winsize', 650, 'overlap', 325, 'nfft', 650})
>
> EEG = pop_select( EEG, 'time' ,[0 1]); %to only extract post-stimulus spectra which is baseline-corrected.
This should be done before precomputing.
> [STUDY specdata_F specfreqs_F pgroup pcond pinter] = std_specplot( STUDY, ALLEEG, 'channels', {'AF3', 'FP1', 'FP2' , 'AFz', 'AF7', 'AF4', 'AF8', 'F5', 'F3', 'F7', 'Fz', 'F2', 'F4',' F6', 'F8'}, ...'averagechan' , 'on', 'plotsubjects', 'off', 'plotconditions', 'together', 'freqrange', [0 30])
This only plots.
> ------------------------
> 650 is the total number of data points in 1.3 seconds of epoch, where 0.3s is baseline and 1sec is post-stimulus. srate= 500Hz
>
> My questions are:
> 1) I don't see the correct units on the Y-axis. If I am not wrong they should be microV sq./ Hz. But I still see microvolts square.
What you are saying sounds correct for the psd method (it should be /hz). However, for FFT, it is the correct unit (for legacy reasons). We will double check.
> 2) I see a peak in the delta band which I hadn't seen before when I ran FFT only and followed the same pop_select method as mentioned above. Why would that be? Is this cause by the artifact because I sub-epoched the 1.3s to 1 second and given that I used window overlapping for PSD, it caused this ?
I doubt this is the case. EEGLAB handles the boundaries.
> If that is true should I instead remove the baseline, then sub epoch and then pre-compute the PSD? What's the best way to go about this?
Once the PSD has been computed, even if you reepoch the data, EEGLAB will use the pre-computed PSD (so yes you need to recompute it).
> 3) Even after running PSD with the abovementioned parameters, the freq resolution is the same and the plots are not smoother than FFT only.
It is hard to know without seeing the data and running a detailed analysis.
The next step would be to look at individual datasets.
Best wishes,
Arno
More information about the eeglablist
mailing list