You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Arnaud Delorme edited this page Mar 9, 2020
·
1 revision
The test below were performed using Python 3.6 but might also work on 2.7. The script below assumes that Python and the pip package are already installed.
First install Octave on your computer. We recommend version 4.4 or later. Second install the Oct2py and MNE librairies as shown below. Then, download the MFF test file and unzip it.
pip install oct2py
pip install mne
Start Python and type the following
# add necessary librairiesfromoct2pyimportoctaveimportmne# add the path to the mffmatlabio plugin - change this line based on your local pathoctave.addpath('/matlab/eeglab/plugins/mffmatlabio')
# note that you should start python in the same folder as this MFF fileEEG=octave.mff_import('NIA_333ms_HCGSN32_test01.mff')
# create MNE structuresch_names=EEG.chanlocs['labels'].tolist();
info=mne.create_info(ch_names=ch_names[0], sfreq=EEG.srate, ch_types='eeg')
raw=mne.io.RawArray(EEG.data, info)
# plot dataraw.plot(scalings={'eeg': 'auto'}, title='Data from MFFMatlabIO')
The plot below will pop up. Extracting event annotation from the will require a little bit more work.