<div dir="ltr"><div class="gmail_default"><font color="#000000"></font></div><div class="gmail_default"><font color="#000000">Hi Joseph, some notes below that should solve this. Best wishes.</font></div><div class="gmail_default"><font color="#000000"><br></font></div><div class="gmail_default"><font color="#000000">*************************************************************************************</font></div><div class="gmail_default"><font color="#000000"><br></font></div><div class="gmail_default"><font color="#000000">after you do it all in the GUI ONLY, type eegh to get the full history of all commands that were run by eeglab, review that very closely and then emulate that.</font></div><div class="gmail_default"><font color="#000000">I think your problem is that you're not properly updating everything via a command such as </font></div><div class="gmail_default"><font color="#000000"><span style="font-size:12.8px">[</span><span class="gmail-il" style="font-size:12.8px;background-color:rgb(255,255,255)">ALLEEG</span><span style="font-size:12.8px"> EEG CURRENTSET] = pop_newset(</span><span class="gmail-il" style="font-size:12.8px;background-color:rgb(255,255,255)">ALLEEG</span><span style="font-size:12.8px">, EEG, </span><span style="font-size:12.8px">CURRENTSET</span><span style="font-size:12.8px">);</span><br></font></div><div class="gmail_default"><span style="font-size:12.8px"><font color="#000000"><br></font></span></div><div class="gmail_default"><span style="font-size:12.8px"><font color="#000000">Further, if your command were working, you should be able to eeglab redraw, and </font></span></div><div class="gmail_default"><span style="font-size:12.8px"><font color="#000000">then you should be able to see 4 loaded datasets in the GUI > Datasets list</font></span></div><div class="gmail_default">If you don't see them, they were not properly loaded.</div><div class="gmail_default"><span style="font-size:12.8px"><font color="#000000"><br></font></span></div><div class="gmail_default"><span style="font-size:12.8px"><font color="#000000"><br></font></span></div><div class="gmail_default"><span style="font-size:12.8px"><font color="#000000">Please review eegh closely after running things in GUI until you build up expertise on what eeglab "expects and needs" to work well.</font></span></div><div class="gmail_default"><font color="#000000"><span style="font-size:12.8px">If you haven't had a chance to, also review online materials about scripting in eeglab.</span></font></div><div class="gmail_default"><font color="#000000"><span style="font-size:12.8px"><br></span></font></div><div class="gmail_default"><font color="#000000"><span style="font-size:12.8px"><br></span></font></div><div class="gmail_default"><span style="font-size:12.8px"><font color="#000000"><br></font></span></div><div class="gmail_default"><span style="font-size:12.8px"><font color="#000000"><br></font></span></div><div class="gmail_extra"><font color="#000000"><br></font><div class="gmail_quote"><font color="#000000">On Fri, May 19, 2017 at 1:03 PM, Joseph Nuamah <span dir="ltr"><<a href="mailto:jknuamah@aggies.ncat.edu" target="_blank">jknuamah@aggies.ncat.edu</a>></span> wrote:<br></font><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><font color="#000000">Hello everyone,</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">I am using pop_mergeset to concatenate four epoched datasets from the same participant.</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">I am able to achieve that with the GUI in EEGLAB. </font></div><div><font color="#000000"><br></font></div><div><font color="#000000">However, I am unable to do that with the Matlab script below. The error I receive tells me the array of all loaded datasets, ALLEEG, is empty. </font></div><div><font color="#000000"><br></font></div><div><font color="#000000">Please find the code below:</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">==============================<wbr>==============================<wbr>=========</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">dpath = 'D:\\MATLAB\\eeglab\\G1\\';</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">EEG = pop_loadset('filename','<wbr>Block1.set','filepath',dpath );</font></div><div><font color="#000000">EEG = eeg_checkset( EEG );</font></div><div><font color="#000000">%clear('EEG')</font></div><div><font color="#000000">EEG = pop_loadset('filename','<wbr>Block2.set','filepath',dpath );</font></div><div><font color="#000000">EEG = eeg_checkset( EEG );</font></div><div><font color="#000000">%clear('EEG')</font></div><div><font color="#000000">EEG = pop_loadset('filename','<wbr>Block3.set','filepath',dpath );</font></div><div><font color="#000000">EEG = eeg_checkset( EEG );</font></div><div><font color="#000000">%clear('EEG')</font></div><div><font color="#000000">EEG = pop_loadset('filename','<wbr>Block4.set','filepath',dpath );</font></div><div><font color="#000000">EEG = eeg_checkset( EEG );</font></div><div><font color="#000000">%clear('EEG')</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">EEG = pop_mergeset( ALLEEG, [1 2 3 4], 0);</font></div><div><font color="#000000">EEG.setname='P1';</font></div><div><font color="#000000">EEG = eeg_checkset( EEG );</font></div><div><font color="#000000">EEG = pop_saveset( EEG, 'filename','P1.set','filepath'<wbr>,'D:\\MATLAB\\eeglab\\G1\\P1\\<wbr>');</font></div><div><font color="#000000">EEG = eeg_checkset( EEG );</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">eeglab redraw;</font></div><div><font color="#000000">==============================<wbr>==============================<wbr>==========</font></div><div><font color="#000000"><br></font></div><div><font color="#000000"><br></font></div><div><font color="#000000"><br></font></div><div><font color="#000000"><br></font></div><div><font color="#000000">This is the error message:</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">==============================<wbr>==============================<wbr>==========</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">Error using pop_mergeset (line 54) needs at least two datasets</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">Error in LoadFiles (line 18) EEG = pop_mergeset( ALLEEG, [1 2 3 4],0);</font></div><div><font color="#000000">==============================<wbr>==============================<wbr>==========</font></div><div><font color="#000000"><br></font></div><div><font color="#000000"><br></font></div><div><font color="#000000"><br></font></div><div><font color="#000000">Please help !</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">Thanks.</font></div><span class="HOEnZb"><font color="#000000"><div><br></div><div>Joseph.</div><div> </div></font></span></div>
<font color="#000000"><br>______________________________<wbr>_________________<br>
Eeglablist page: <a href="http://sccn.ucsd.edu/eeglab/eeglabmail.html" rel="noreferrer" target="_blank">http://sccn.ucsd.edu/eeglab/<wbr>eeglabmail.html</a><br>
To unsubscribe, send an empty email to <a href="mailto:eeglablist-unsubscribe@sccn.ucsd.edu">eeglablist-unsubscribe@sccn.<wbr>ucsd.edu</a><br>
For digest mode, send an email with the subject "set digest mime" to <a href="mailto:eeglablist-request@sccn.ucsd.edu">eeglablist-request@sccn.ucsd.<wbr>edu</a><br></font></blockquote></div><br></div></div>