<div dir="ltr">Dear Brandon,<div><br></div><div>Try this:</div><div><br></div><div><div>% extract all event labels</div><div>eventList = {EEG.event.type}';</div><div>% identify their index numbers</div><div>eventIdx = find(strcmp(eventList, 'fix+'));</div>
<div>% add constant to the latencies</div><div>for n = 1:length(eventIdx)</div><div> EEG.event(eventIdx(n)).latency = EEG.event(eventIdx(n)).latency+50;</div><div>end</div></div><div>% redraw eeglab</div><div>eeglab redraw</div>
<div><br></div><div>Makoto</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Jun 24, 2014 at 4:40 PM, Brandon W. Ng <span dir="ltr"><<a href="mailto:brandonng2011@u.northwestern.edu" target="_blank">brandonng2011@u.northwestern.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Dear EEG Lab List,<div><br></div><div>I had a quick question about how to correct for trigger time delays. My time delay for my study is about 50 ms, and according to the site, using the function erptimeshift(erp, amount of delay) should adjust the dataset to fix the problem, but whenever I employ the function, I get the following error, and I am not sure how to fix this.</div>
<div><br></div><div>Is there something that I need to do (re-formatting my ERP) to fix the problem? Any help would be appreciated.</div><div><br></div><div><br></div><div>>> erptimeshift('61_ERPs.erp', 50)<div>
Attempt to reference field of non-structure array.</div><div><br></div><div>Error in erptimeshift (line 52)</div><div>fulltime = (ERP.xmax-ERP.xmin)*1000;</div><div><br></div><div><br></div><div><br></div><div><br></div>
<div>
Thanks,</div><div><br></div><div>Brandon</div><span class="HOEnZb"><font color="#888888">-- <br><div dir="ltr"><br><b>Brandon W. Ng, M.A.</b><div>PhD Student in Cultural Neuroscience, University of Virginia</div><div>BA with Dual Honors, <i>Phi Beta Kappa</i>, Northwestern University</div>
<div>UVA Morris Social Neuroscience Lab</div><div>UVA Oishi Culture and Well-Being Lab</div><div>E-Mail: <a href="mailto:brandonng2011@u.northwestern.edu" target="_blank">brandonng2011@u.northwestern.edu</a></div><div>Website: <a href="http://www.epernicus.com/bwn" target="_blank">http://www.epernicus.com/bwn</a></div>
<div><a href="http://uvasocialneuroscience.com/" target="_blank">http://uvasocialneuroscience.com/</a></div><div><br></div><div><br></div></div>
</font></span></div></div>
<br>_______________________________________________<br>
Eeglablist page: <a href="http://sccn.ucsd.edu/eeglab/eeglabmail.html" target="_blank">http://sccn.ucsd.edu/eeglab/eeglabmail.html</a><br>
To unsubscribe, send an empty email to <a href="mailto:eeglablist-unsubscribe@sccn.ucsd.edu">eeglablist-unsubscribe@sccn.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.edu</a><br></blockquote></div><br><br clear="all"><div><br></div>
-- <br><div dir="ltr">Makoto Miyakoshi<br>Swartz Center for Computational Neuroscience<br>Institute for Neural Computation, University of California San Diego<br></div>
</div>