mne.viz.plot_raw automatically applies selected channels as bad channels

Hi,

Whenever I use the mne.viz.plot_raw function to plot my raw data, it opens an interactive plot.
So far so good.

The weird thing: when I click channels and close the GUI, it automatically applies my selection as bad channels. I don’t understand why. I don’t apply them manually anywhere. I just use the function to plot.

Is this the expected the behavior?
The bad channel marking feature and the fact that it occurs in place is not documented anywhere as far as I can tell. What if I want to mark channels in the raw data for purposes other than marking bad channels?

Am I losing my mind?

Please advise.

Hello @MichaelSel,

this is the expected behavior. It’s documented in the Notes section at mne.io.Raw — MNE 0.23.4 documentation

The changes are in fact applied immediately upon clicking, not only after closing the figure.

If you think the documentation could be improved: proposals are highly appreciated!

Best wishes,
Richard

1 Like