MneExperiment.make_epoch_selection(samplingrate=None, data=None, auto=None, overwrite=None, decim=None, **state)

Open gui.select_epochs() for manual epoch selection

The GUI is opened with the correct file name; if the corresponding file exists, it is loaded, and upon saving the correct path is the default.

  • samplingrate (Optional[int]) – Samplingrate in Hz for the visualization (set to a lower value to improve GUI performance; the default is the epoch setting).

  • data (Optional[str]) – For data with multiple channel types, specify the channel type to display (mag, planar1, planar2).

  • auto (scalar (optional)) – Perform automatic rejection instead of showing the GUI by supplying a an absolute threshold (for example, 1e-12 to reject any epoch in which the absolute of at least one channel exceeds 1 picotesla). If a rejection file already exists also set overwrite=True. When working with data from multiple sensor types, use a dictionary to set levels for all types, e.g. {'mag': 2e-12, 'grad': 5e-11, 'eeg': 1.5e-4}.

  • overwrite (bool) – If auto is specified and a rejection file already exists, overwrite the old file. The default is to raise an IOError if the file exists (None). Set to False to quietly keep the exising file.

  • decim (Optional[int]) – Data decimation factor (alternative to samplingrate).

  • ... – State parameters.


By default, the epoch selection is different for each primary epoch and for each preprocessing setting (raw). To share the same epoch selection, the corresponding selection file can be duplicated. To quickly duplicate the files for several subjects from one preprocessing setting to another, use make_copy():

for subject in e:
    e.make_copy('rej-file', 'raw', '0.1-40', '1-20')