[Eeglablist] Using EEGLAB from within a function
b.osuagwu.1 at research.gla.ac.uk
Sun Jan 26 07:47:42 PST 2014
There are many ways you can do this. One is to start EEGLAB normally before running your function: [ALLEEG EEG CURRENTSET ALLCOM] = eeglab;
Then define ALLEEG, EEG, CURRENTSET as globals inside your function.
From: eeglablist-bounces at sccn.ucsd.edu [eeglablist-bounces at sccn.ucsd.edu] On Behalf Of David Kaufman [david.kaufman at gmx.de]
Sent: 24 January 2014 08:41
To: eeglablist at sccn.ucsd.edu
Subject: [Eeglablist] Using EEGLAB from within a function
I'm trying to use EEGLAB from within a function inside a script, e.g.
[ALLEEG EEG CURRENTSET ALLCOM] = eeglab;
EEG = pop_loadbv(baseFolder, eegFile);
[ALLEEG EEG CURRENTSET] = eeg_store(ALLEEG, EEG, CURRENTSET)
Unfortunatly, as soon as the function returns my data set is not present in the GUI. If I put the contents of the above function in the root script the data set appears in the GUI.
Is it possible to call EEGLAB from a function and also see the data set or am I using EEGLAB wrong?
More information about the eeglablist