problem dropping epochs by visual inspection
See original GitHub issueFound a problem regarding dropping epochs. You can try it with the data of the read epochs example.
Plotting epochs and selecting bad epochs by hand results in a reduction of the total number of epochs. This does not work plotting only the epochs corresponding to a certain event_id
.
Doing it for the whole set:
epochs
Out[2]: <Epochs | n_events : 55 (all good), tmin : -0.199795213158 (s), tmax : 0.499488032896 (s), baseline : (None, 0), ~17.5 MB, data loaded>
epochs.plot()
Out[3]: <matplotlib.figure.Figure at 0xc8afda0>Dropped 5 epochs
Channels marked as bad: []
epochs
Out[4]: <Epochs | n_events : 50 (all good), tmin : -0.199795213158 (s), tmax : 0.499488032896 (s), baseline : (None, 0), ~16.3 MB, data loaded>
5 epochs are marked as bad -> the total number of epochs is reduced by five
Plotting only epochs corresponding to an event_id
:
epochs['1']
Out[2]: <Epochs | n_events : 55 (all good), tmin : -0.199795213158 (s), tmax : 0.499488032896 (s), baseline : (None, 0), ~17.5 MB, data loaded>
epochs['1'].plot()
Out[3]: <matplotlib.figure.Figure at 0xa250978>Dropped 5 epochs
Channels marked as bad: []
epochs['1']
Out[4]: <Epochs | n_events : 55 (all good), tmin : -0.199795213158 (s), tmax : 0.499488032896 (s), baseline : (None, 0), ~17.5 MB, data loaded>
5 epochs are marked as bad -> the total number of epochs stays the same
Issue Analytics
- State:
- Created 6 years ago
- Comments:11 (11 by maintainers)
Top Results From Across the Web
mne.Epochs — MNE 1.2.2 documentation - MNE-Python
Reject epochs based on maximum peak-to-peak signal amplitude (PTP), i.e. the absolute difference between the lowest and the highest signal value ...
Read more >Epochs - Mainak Jas
You can also inspect the reason why epochs were dropped. The indices from the original set of events are stored in epochs. selection...
Read more >Use Early Stopping to Halt the Training of Neural Networks At ...
Too many epochs can lead to overfitting of the training dataset, whereas too few may result in an underfit model. Early stopping is...
Read more >The Epochs data structure - | notebook.community
Selecting epochs by index · Selecting, dropping, and reordering channels · Changing channel name and type · Selection in the time domain ·...
Read more >Check for ICA (toward Epochs Rejection) - MNE Forum
Also you should drop this line – you only have EEG data, so specifying rejection thresholds on MEG channels doesn't make much sense....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Argh yes
selection
gets restricted. Fortunately we can use event numbers, though. See if this makes sense:Closing since the main problem can by solved by a NumPy-based workflow. @stfnrpplngr if you are still interested in the other features you mention in your last post, feel free to open new issues for discussion