Back to the main page.

Bug 3357 - padding for spectral interpolation should be removed from ft_specest_hilbert

Status ASSIGNED
Reported 2017-09-26 23:45:00 +0200
Modified 2017-09-26 23:45:55 +0200
Product: FieldTrip
Component: specest
Version: unspecified
Hardware: PC
Operating System: Mac OS
Importance: P5 normal
Assigned to: Roemer van der Meij
URL:
Tags:
Depends on:
Blocks:
See also:

Roemer van der Meij - 2017-09-26 23:45:14 +0200

It serves no purpose. We use it in specest_XXX to obtain Fourier coefficients at a particular frequency (e.g. integer Hz) so that we can compare them easily between e.g. trials with variable length. In specest_hilbert, it is used only when performing the hilbert, and here it is pointless. The Hilbert calculates the imaginary component of the signal using all the information (frequencies) present. If the fft inside the hilbert transform is padded with zero's, no new information is created, and the estimate of the imaginary component will be unaffected. In case you are also wondering, wait, aren't all these approaches equivalent at their basic form? (e.g. Bruns 2004). Then why would it be pointless for specest_hilbert and not specest_mtmconvol? The crucial link between complex-convolution and filtering+hilbert in this situation, I think, would be that the spectral interpolation in the latter would be equivalent to temporal interpolation *prior* to filtering in the former. This would result in the filter being tuned more appropriately to the desired center frequency. OR, the algorithm(s) for creating the filter coefficients already deal with this in some manner, and the temporal interpolation would be circumvented. (This is not related to the pull request regarding NaNing edge artifacts I'm about to make)