Advice on formation of epochs with events of varied duration and uneven (or nonexistent) sample.

  • MNE version: 1.0.3
  • operating system: Windows 11
      epochs = mne.Epochs(filt_raw, events, event_id, tmin, tmax, proj=False,
                                picks=picks, baseline=baseline,
                                preload=False, event_repeated='merge',
                                reject=reject)

To briefly summarize, I have a study in which the occurrence of events largely varies between participants. Events (a snippet) are labeled in annotation as:

1.2
1.3
2.1
2.2

Furthermore, these events are also broken down into sub-events of 1.2.1, 1.2.2, 1.3.1, 1.3.2…, where X.X.1 refers to (intended) epochs where participants failed the corresponding X.X condition, and X.X.2 where participants passed respectively. As such, it is plausible that a participant passes everything in for instance, 1.2, with all sub-events exactly duplicated (in annotations) into 1.2.2 with no 1.2.1s.

All of these events are dynamic, and can range from as brief as a few seconds, to as long as 15± minutes. Naturally, the anticipated analysis here would be broad based frequency band analysis that looks at average freq band activity during the entire duration of event, rather than ERP.

My questions are:

  1. mne.Epochs currently needs to be predefined by tmin and tmax. Is there a way for epochs to be formed based on the initial event start and stop time, as already defined in annotation?

  2. mne.Epochs’ event_repeated options are ‘merge’, ‘drop’ and ‘error’ currently. Is there a way to ignore repeated events? Because currently, due to sub-events overlapping the main events (passes and fails essentially take up the exact same time range of their main events), mne.Epochs seem to be discarding data, when I want all main events and sub events to be preserved. As reference, below include the initial count of all event types, and event count after it has undergone merger, which separately, I am also confused as to why distinct events such as 1.5 are fused with 4.X. Note that the sum of X.X.1 and X.X.2 would logically be its parent X.X.

Event Counts (sorted):
1.1: 2
1.1.2: 2
1.3: 1
1.3.1: 1
1.5: 4
1.5.2: 4
1.6: 6
1.6.1: 1
1.6.2: 5
1.7: 2
1.7.1: 1
1.7.2: 1
2.1: 2
2.1.1: 2
3.1: 37
3.1.1: 6
3.1.2: 31
4.1: 1
4.1.1: 1
4.2: 1
4.2.1: 1
4.3: 1
4.3.1: 1
4.4: 1
4.4.1: 1
BAD_NOISY: 412

epochs
Out[5]: 
<Epochs |  15 events (all good), -3 - 3 sec, baseline -3 – 0 sec, ~35 kB, data not loaded,
 '1.1': 1
 '1.3': 0
 '1.6': 2
 '1.7': 0
 '2.1': 0
 '3.1': 12
 '1.5/4.1': 0
 '1.5/4.4': 0
 '1.5/4.3': 0
 '1.5/4.2': 0>

I am aware of the unusual experimental setup that I have laid out. But the general aim of the study is to look at band activity differences across different event types regardless of time, as well as how band activity varies between passing and failing the different events, and this is what I ended up with. Nevertheless, please do also advice on any methodological concerns, if you have any.