<div><br></div><div>Becky,</div><div><br></div><div>It may be relevant to your problem that at least one of</div><div>your event types has trailing spaces (the one that you</div><div>presented as example - 55).</div><div><br>
</div><div>As you wrote matlab displays the type as:</div><div>type: '55 '</div><div><br></div><div>which means there are two spaces after two five characters.</div><div>I'm not sure if it should make any difference for</div>
<div>EEGLAB in displaying event types, but it could cause</div><div>the error you report (empty epoch range), because you</div><div>may not have any '55' event types, but '55 ' instead.</div><div><br></div>
<div>You may do a quickcheck of this by coping the following code:</div><div><br></div><div>types = unique({EEG.event.type});</div><div>which_have_spaces = cellfun(@isempty, regexp(types, ' '));</div><div>if ~isempty(which_have_spaces)</div>
<div>types_with_spaces = types(which_have_spaces);</div><div>end</div><div><br></div><div>If this is the case you could then deblank all the events</div><div>and urevents by looping through them and see if it makes</div><div>
any difference.</div><div>Anyway, once you find your spaced event types, you could</div><div>also try using pop_epoch again, but with correct event</div><div>types.</div><div><br></div><div>Mikolaj</div>