[FieldTrip] ft_freqanalysis and optimal parameters for higher frequency

Matt Craddock m.p.craddock at leeds.ac.uk
Fri Sep 4 17:22:52 CEST 2015


On 03/09/2015 18:28, Grazia Di Pisa wrote:
> Hi all,
>
> I’m doing time-frequency analysis based on multitapers since I’m trying
> to analyse activity in the gamma band frequency from 30 to 80 Hz.
>
> I’m getting some strange plots and from the tutorial I don’t understand
> how to optimally choose some parameters, in particular for cfg.t_ftimwin
> and cfg.tapsmofrq.
>
> Currently, I’m using the following:
>
> cfg = [];
>      cfg.output     = 'pow';
>      cfg.channel    = 'EEG';
>      cfg.method     = 'mtmconvol';
>      cfg.toi        = [-1.0 : 0.05 : 2.5];
>      cfg.foi        = [30:2:80];
>      cfg.t_ftimwin  = 5./cfg.foi;
>      cfg.tapsmofrq  = 0.4*cfg.foi;
>
> Sorry for the very basic question, but I’m a beginner so some
> explanations and suggestions would be really helpful!
>
> Thanks in advance,
> ~ grazia
>

Hi Grazia,

without seeing the plots it's a little difficult to be sure what you 
mean by strange.

The parameters are fine in the sense that they will work. They're set to 
scale the length of the time window and the amount of frequency 
smoothing by frequency. So as frequency increases, the time window 
shortens (and thus frequency precision decreases), and the amount of 
smoothing increases as well. The length of the time window is an integer 
number of cycles at that frequency; so in this case, the time window is 
5 cycles at each frequency. You could try a higher number of cycles; 
with Morlet wavelets, 7 cycles are often used for high frequency 
activity, so maybe try 7. Also, the amount of smoothing scales here such 
that at 80 Hz you have 32 Hz of smoothing... that seems a little 
excessive to me.

Often you'll find when people use multitapers to analyze gamma they'll 
use fixed rather than scaling time windows and smoothing. So for 
example, you could set:

cfg.t_ftimwin(1:length(cfg.foi)) = 0.2;
cfg.tapsmofrq(1:length(cfg.foi)) = 10;

to use a fixed window length of 200 ms and smoothing of 10 Hz. I usually 
do it this way. to check the frequency resolution of the window, divide 
1 by it. So here, it's 1/.2 = 5 Hz. The smoothing should be a multiple 
of this, so 10, 15, 20 and so on. 2 or 3 times the resolution should be 
OK, so 10 or 15 with a window of .2s.

It's hard to say what's optimal as that depends on the nature of the 
signal, but generally with settings like the above you'll probably see 
something if anything is there

If you're looking at gamma band with the EEG, be *extremely* wary of 
miniature eye movement artefacts. See...

Keren, A. S., Yuval-Greenberg, S., & Deouell, L. Y. (2010). Saccadic 
spike potentials in gamma-band EEG: Characterization, detection and 
suppression. NeuroImage, 49(3), 2248–2263. 
http://doi.org/10.1016/j.neuroimage.2009.10.057

Hassler, U., Barreto, N. T., & Gruber, T. (2011). Induced gamma band 
responses in human EEG after the control of miniature saccadic 
artifacts. NeuroImage, 57(54), 1411–1421. 
http://doi.org/10.1016/j.neuroimage.2011.05.062

...and my eeglab plugin here: https://github.com/craddm/microDetect

Cheers,
Matt

-- 
Dr Matt Craddock
Research Fellow
School of Psychology
University of Leeds
Tel: +44 113 3430540



More information about the fieldtrip mailing list