MATLAB, although quite efficient, can be expensive. As of 2021, we are supporting the Octave MATLAB-compatible open-source environment (both command line calls and graphic interface). See the video below for information on running EEGLAB in Octave.
EEGLAB on Octave is not as stable as EEGLAB on Matlab. EEGLAB on Matlab should be your first choice. Your second choice should be the compiled version of EEGLAB, and the third and last choice should be EEGLAB on Octave.
Download the latest version of Octave from this page. EEGLAB has been best tested using Octave 6.1 on Windows but might also run on later versions and other platforms. We recommend the Octave installer for Windows, which has all toolboxes (signal processing, statistics, etc…) pre-installed.
To avoid having Octave show warning messages constantly, change the startup option and add “–traditional –brainless –quiet” (on Windows, select the Octave icon’s property, and add the following options to the Target field).
If you are running Octave on Linux or macOS, in addition to Octave, you will need to install the Octave signal processing and statistics package. On the Octave command line, type:
pkg install -forge control pkg install -forge signal pkg load signal pkg install -forge io pkg install -forge statistics pkg load statistics
Note that you need to run the last command pkg load signal and pkg load statistics every time you start Octave.
EEGLAB for Octave is a work in progress. As of EEGLAB 2021.0, we recommend using the development version of EEGLAB on GitHub. For later EEGLAB versions, you may use the official EEGLAB releases.
All EEGLAB signal processing functions should run on Octave. Although Octave is supposed to be fully compatible with MATLAB, the Octave graphic rendering engine sometimes cannot render all EEGLAB graphics subtleties. In particular, we have encountered the following issues:
- Graphical figure updating is buggy. Users must move their mouse for multi-panel figures to be updated. Or sometimes, the figure itself must be moved or resized to be shown properly. For example, the eegplot.m interactive data scrolling function is not fully functional: selecting data regions in continuous data involves waiting for 10 seconds or so between mouse clicks.
- Speed: Processing data is often about twice slower in Octave.
- Plug-ins need to be installed manually (downloaded as zip files and uncompressed in the EEGLAB plugins folder). Most plugins (including SIFT and LIMO) have not been tested on Octave and will likely not be functional. They could probably be made functional by their developers or by motivated users.
Nevertheless, even some of the most complex EEGLAB plots can be rendered on Octave - for example, below, dipole plots in MATLAB (left) and Octave (right) match perfectly.
If you modify an interactive EEGLAB function for that purpose and want others to benefit from your changes, fork the code and create a pull request as explained on this page. This other page contains additional information on how to contribute to EEGLAB.
Below is a time-frequency decomposition plotted by Octave 4.4 for the EEGLAB tutorial dataset by the EEGLAB/MATLAB code below.
% cd xxxxx/eeglab % move to the proper directory/folder % octave --traditional % start Octave eeglab; % call EEGLAB EEG = pop_loadset('sample_data/eeglab_data_epochs_ica.set'); % load an EEGLAB dataset newtimef(EEG.data(1,:,:), EEG.pnts, [-1000 2000], EEG.srate, [3 0.5]); % compute and plot a trial-average ERSP
For comparison, below is the graphic output of newtimef.m run in MATLAB.