-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
WIP, BUG: Make plot_evoked() not plot GFP for single channel #8774
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP, BUG: Make plot_evoked() not plot GFP for single channel #8774
Conversation
drammock
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changes look reasonable. +1 for merge when CIs are happy
|
Please do not merge yet, I figured there's actually a bug in how we calculate GFP. |
The reason for mne-tools#8772 is simply that we always calculated the GFP incorrectly, i.e. without re-referencing sensor signals to average first. When doing that, I now correctly get a flat GFP (0 at all time points) for single-channel recordings. Closes mne-tools#8772, mne-tools#8774
|
@cbrnr merge if happy |
|
Thanks @hoechenberger! |
|
Oh noes this wasn't supposed to be merged… can we revert? |
|
Can you open a new PR to revert? Sorry about that, I thought you'd addressed the issue (the PR was not a draft and @agramfort said OK to merge). |
|
Was this simply reset once @agramfort submitted his review? |
…ne-tools#8774)" This reverts commit ae8a466.
|
Hmmm, must've been otherwise it wouldn't have let me merge... Very strange! |
|
It's my fault.... Sorry and thanks for reverting. |
The reason for mne-tools#8772 is simply that we always calculated the GFP incorrectly, i.e. without re-referencing sensor signals to average first. When doing that, I now correctly get a flat GFP (0 at all time points) for single-channel recordings. Closes mne-tools#8772, mne-tools#8774
* GFP was not derived from average-referenced signal as it must be The reason for #8772 is simply that we always calculated the GFP incorrectly, i.e. without re-referencing sensor signals to average first. When doing that, I now correctly get a flat GFP (0 at all time points) for single-channel recordings. Closes #8772, #8774 * Add GFP to EEG tutorial [skip azp][skip github] * Fix doc build [skip azp][skip github] * style [skip azp][skip github] * phrasing [skip github][skip azp] * Small fixes [skip azp][skip github] * Apply suggestions from code review [skip azp][skip github] Co-authored-by: Daniel McCloy <dan@mccloy.info> * Fix [skip azp][skip github] * Small fixes + adjust color [skip azp][skip github] * Add gfp='power', gfp='power-only' * Better docstring rendering * use np.linalg.norm Co-authored-by: Alexandre Gramfort <alexandre.gramfort@m4x.org> * power -> rms * GFP for EEG, RMS for MEG * Touch Evoked tutorial * Update changelog * Fix tests * FIX: Doc and test * Frobenius norm -> RMS Co-authored-by: Daniel McCloy <dan@mccloy.info> Co-authored-by: Alexandre Gramfort <alexandre.gramfort@m4x.org> Co-authored-by: Eric Larson <larson.eric.d@gmail.com>
* GFP was not derived from average-referenced signal as it must be The reason for #8772 is simply that we always calculated the GFP incorrectly, i.e. without re-referencing sensor signals to average first. When doing that, I now correctly get a flat GFP (0 at all time points) for single-channel recordings. Closes #8772, #8774 * Add GFP to EEG tutorial [skip azp][skip github] * Fix doc build [skip azp][skip github] * style [skip azp][skip github] * phrasing [skip github][skip azp] * Small fixes [skip azp][skip github] * Apply suggestions from code review [skip azp][skip github] Co-authored-by: Daniel McCloy <dan@mccloy.info> * Fix [skip azp][skip github] * Small fixes + adjust color [skip azp][skip github] * Add gfp='power', gfp='power-only' * Better docstring rendering * use np.linalg.norm Co-authored-by: Alexandre Gramfort <alexandre.gramfort@m4x.org> * power -> rms * GFP for EEG, RMS for MEG * Touch Evoked tutorial * Update changelog * Fix tests * FIX: Doc and test * Frobenius norm -> RMS Co-authored-by: Daniel McCloy <dan@mccloy.info> Co-authored-by: Alexandre Gramfort <alexandre.gramfort@m4x.org> Co-authored-by: Eric Larson <larson.eric.d@gmail.com>

Fixes #8772