Using compute_TFR or similar with EpochsEEGLAB

MNE version: 1.6.1
operating system: Windows 10

Hello,

I am interesting in looking at ERDS (or other ERP characteristics) in my EEG data.

The data is preprocessed (filtered, downsampled, ICA’d, events added, and epoched) in EEGLAB, and saved as a .set file.

I loaded the set file as following:

epochs = mne.read_epochs_eeglab(set_file)

and epochs looks correct (# of Events, time range, baseline are correct).

Plotting also works, but when I try to use:

epochs.compute_tfr()

I received the following:

----> 1 epochs.compute_tfr()

AttributeError: 'EpochsEEGLAB' object has no attribute 'compute_tfr'

I understand this is likely because mne.read_epochs_eeglab does not actually return an epochs class but instead EpochsEEGLAB (this has been clarified before (Be more explicit about what is returned by read_epochs_eeglab and read_epochs_kit · Issue #12542 · mne-tools/mne-python · GitHub).

I guess my question is are there existing methods to either convert my EpochsEEGLAB into a usable Epochs class, or a different way to load the .set file to allow it?

This is likely due to your version of MNE. If you look at the documentation of Epochs.compute_tfr, you’ll see New in v1.7 in the Notes section.
If you update your MNE version, you will have access to this new method, released on the 19th of April 2024.

Mathieu

2 Likes

Works! Thanks!

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.