Hello,
For some reason epochs.plot() only shows the epochs but not the events. I used the same code as in the tutorial, but the plot looks different:
bids_root = pathlib.Path('out_data/sample_BIDS')
bids_path = mne_bids.BIDSPath(subject='01',
                              session='01',
                              task='audiovisual',
                              run='01',
                              datatype='meg',
                              root=bids_root)
raw = mne_bids.read_raw_bids(bids_path)
raw.load_data()
raw.filter(l_freq=0.1, h_freq=40)
events, event_id = mne.events_from_annotations(raw)
event_id
Output:
{‘Auditory/Left’: 1,
‘Auditory/Right’: 2,
‘Button’: 3,
‘Smiley’: 4,
‘Visual/Left’: 5,
‘Visual/Right’: 6}
tmin = -0.3 
tmax = 0.5 
baseline = (None, 0) 
epochs = mne.Epochs(raw, 
                    events=events, 
                    event_id=event_id, 
                    tmin=tmin, 
                    tmax=tmax,
                    baseline=baseline, 
                    preload=True)
epochs.plot()
Output: left is what I expect it to look like, right is what I actually get. Why doesn’t it show the events?
I use
conda 4.10.1
Python 3.9.2
MNE 0.22.1
Windows 10


