mne-tools / mne-tools/mne-python
varying bandwith for multitapers
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 3.5k
- Forks
- 1.6k
- Avg merge
- 1d 6h
- Merged PRs (30d)
- 100
Description
Describe the new feature or enhancement
I want to freely define the amount of temporal and spatial smoothing in a multitaper analysis. As far as I understand, currently, the bandwidth of the multitapers is a fixed value for all frequencies.
E.g. I want to have 1 Taper (thus no SNR increase) for frequencies up to 16Hz, with a frequency smoothing of 3/4 octave (thus changing time-windows), from 16Hz on, I want to fix the timwindow to 0.25s and use increasing amount of multitapers to smooth (and make gains from the SNR increase).
As an example this is how I would want to specify my TF analysis:
freqs = np.arange(5,32,1)
#time-window= n_cycles / freq.
#freq_smoothing = time_bandwith/time-window
# The windows should have 3/4 octave smoothing in frequency domain
freq_window = freqs*2**(3/4/2) - freqs*2**(-3/4/2)
# The timewindow should be so, that for freqs below 16, it results in n=1
# Taper used, but for frequencies higher, it should be a constant 250ms.
time_window = 2/freq_window
time_window[freqs>=16] = 0.25
time_bandwidth = freq_window*time_window
n_cycles = time_window*freqs
Describe your proposed implementation
I am not familiar enough with the current TF implementation to really help here.
Additional comments
Fieldtrip allows for such schemes and they are used in the literature (e.g. Hipp 2012)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the current time-frequency multitaper implementation and reading how it sets bandwidth, time windows, and taper counts. Done means supporting frequency-dependent temporal and spatial smoothing, including the example's single-taper low-frequency region and fixed 0.25-second windows above 16 Hz.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100