Epochs on resting state data on MEG (mne.make_fixed_length_epochs)

  • MNE version: 1.2.3
  • operating system: Windows 11

**:page_facing_up: I´m dealing with issues in generating the epochs on resting state data on MEG.

I want to create fixed length epochs of 2 seconds duration on filtered data (high pass and notch) . This is basically the code i use for filtering:
raw_highpass = raw.filter(l_freq=0.1, h_freq=None) #aplico el filtro
raw_notch = raw_highpass.copy().notch_filter(freqs=np.arange(50, 251, 50))

I´m using this code to create the epochs:
epochs = mne.make_fixed_length_epochs(raw_notch, duration=3, preload=True)

When I use compute_psd() and then .plot, this power spectrum appears:
epochs.compute_psd(fmax=120).plot()

In this plot there appers a lof of changes in the amplitude of different frequencies.

But if I compute_psd().plot() raw_notch , or raw this doesn´t happen :

raw_notch.compute_psd(fmax=120).plot()

I´ve also tried other functions (like the one below), but the same problem appears

events= mne.make_fixed_length_events(raw_notch, id=1,start=0, duration=2, first_samp=False)

epochs=mne.Epochs(raw_notch, events=events,  baseline=None, tmin=0, tmax=2, preload=True,picks="all")