ucdavis / erplab

ERPLAB Toolbox is a free, open-source Matlab package for analyzing ERP data. It is tightly integrated with EEGLAB Toolbox, extending EEGLAB’s capabilities to provide robust, industrial-strength tools for ERP processing, visualization, and analysis. A graphical user interface makes it easy for beginners to learn, and Matlab scripting provides enormous power for intermediate and advanced users.
http://erpinfo.org/erplab
267 stars 73 forks source link

Binlister error #187

Open pb865 opened 8 months ago

pb865 commented 8 months ago

Description

While trying to use the binlister, two errors are returned:


Error in neobinlister2 (line 280)
        cd1 = EVENTLIST.eventinfo(iLogitem).enable~=-1 && ~ismember(EVENTLIST.eventinfo(iLogitem).code, forbiddenCodeArray);

Error in pop_binlister (line 436)
        [EEG, EVENTLIST, binofbins, isparsenum] = neobinlister2(EEG, file1, file2, file3, forbiddenCodeArray, ignoreCodeArray, 0);

EEG refers to the EEG file I am trying to process. This set is part of a preprocessing for-loop I have written. The line of code that produces this error is:

EEG  = pop_binlister( EEG , 'BDF', [DIR1 '/' 'WIT_key_bins_v3.txt'], 'ExportEL', [DIR3 '/' SUB{i} '_WIT_eventlist_bins.txt'], 'IndexEL',  1, 'SendEL2', 'EEG&Text', 'UpdateEEG', 'on', 'Voutput', 'EEG' );

Where EEG is my EEG file, ``DIR1``` is the directory to where the binlister txt file is, and DIR3 is the output directory.

My binlister text file looks like this:

bin 1

BPG_Correct

.{15}

bin 2

BPG_Incorrect

.{16}

bin 3

BPT_Correct

.{18}

bin 4

BPT_Incorrect

.{19}

bin 5

WPG_Correct

.{24}

bin 6

WPG_Incorrect

.{25}

bin 7

WPT_Correct

.{27}

bin 8

WPT_Incorrect

.{28}

"AND" and "OR" do not apply in terms of my bins, so I'm not quite sure to what this error is referring.


Expected behavior:

Bin the events based on my binlister .txt file.


Actual behavior:

Errors returned. Could not complete preprocessing.


Versions

OS version [Windows 11 Education version 23H2]
Matlab version [23.2.0.2365128 (R2023b)]
EEGLAB version [2023.0]
ERPLAB version [v10.0]
davidg622 commented 8 months ago

Hello,

Does the same error occur when you use Binlister through the GUI? If so, please send me a sample of your data and the Binlister file to my email address, drgarrett@ucdavis.edu, where I can try to diagnose the problem.

Thanks, David