Issues with loading and visualising .mat data with use of mne python

92 Views Asked by At

I am working on an EEG dataset and I have been trying to use mne python but I haven't been able to load my .mat data or visualise it. I would be very grateful if anyone could helpe with it. Thank you!

For loading the .mat data when I use mne.read_evoked_filedtrip()or mne.read_epochs_fieldtrip. I get errors usually TypeError:missing 1 required positional argument:'info'. I was able to load the data with the help of scipy loadmat but I am not sure how to visualise and process the data.

1

There are 1 best solutions below

0
Iman Faisal On

I faced the same issue. You can use some mne functions for MAT v4 files that are loaded into NumPy arays with scipy.io.loadmat(). I've used the mne.filter.notch_filter() successfully on an EEG NumPy array without having to convert the data into mne's Raw format.

However if you want to use the full breadth of the library then converting into Raw is your best bet and is quite simple too. Someone posted how to do so here, all you need is the sampling frequency and number of channels to create an Info object to pass into the mne.io.RawArray() function along with your EEG data extracted using scipy.io from the .mat file.