[Eeglablist] script for importing .mat files

Muhammad Adeel Parvaz mparvaz at gmail.com
Thu Jan 1 20:11:52 PST 2015


Hi,

I am new to EEGLAB. I have an EEG data (.mat) that I can successfully
import it in EEGLAB, use the last channel (#65) to load events and then
save the data as a .set and .fdt pair. However, I have about 80 of these
files and I would like to repeat these 3 processes to each of these files.
I looked into doing it through GUI on the first file and then using the
dataset history to get the commands for each step and applying to other
files, but I am not quite sure how to do that.

By the way, I can manually import a bunch of files and then run the history
commands to automatically perform the other two steps. So, the automatic
import seems to be the limiting factor. I would ideally like the script to
run through the directory and perform these steps on each file.

My command history for one dataset looks like this:

pop_read_gtec(ALLEEG) % importing function supplied by the vendor
EEG = eeg_checkset( EEG );
EEG = pop_chanevent(EEG, 65,'edge','leading','edgelen',0);
EEG = eeg_checkset( EEG );
EEG = pop_saveset( EEG,
'filename','S001_Oddball.set','filepath','C:\\Users\\Documents\\MATLABfiles\\EEG_Data\\Test\\');
EEG = eeg_checkset( EEG );

Any and every help would be much appreciated.

Thanks and a happy new year!

-Muhammad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://sccn.ucsd.edu/pipermail/eeglablist/attachments/20150101/c52ea747/attachment.html>


More information about the eeglablist mailing list