How window window size is inferred?

External Email - Use Caution

Dear MNE-community,

In example "Decoding in time-frequency space data using the Common Spatial
Pattern (CSP)" (
https://mne-tools.github.io/dev/auto_examples/decoding/plot_decoding_csp_timefreq.html#sphx-glr-auto-examples-decoding-plot-decoding-csp-timefreq-py),
I did not understand the concept behind inferring window size based on
frequency being used(line 81-82). Can you please explain shortly why and
how window size is inferred?

Regards
Manoj
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.nmr.mgh.harvard.edu/pipermail/mne_analysis/attachments/20190512/b70ce92e/attachment.html

External Email - Use Caution

I guess you refer to these lines:

    # Infer window size based on the frequency being used
    w_size = n_cycles / ((fmax + fmin) / 2.) # in seconds

the size of the filter applied depends on the filtering. For low frequencies
you need longer filters. I guess this is a way to inject this idea
when cropping time windows.

Hope this helps
Alex