artifact rejection

Jasper Poort j.poort at NIN.KNAW.NL
Wed Aug 16 16:59:43 CEST 2006


Hi all, 

I noticed a problem with artifact viewer:

when I perform artifact rejection with cfg.interactive='yes', I get the following error message:

        ??? Subscript indices must either be real positive integers or logicals.

        Error in ==> fieldtrip\private\artifact_viewer>read_and_plot at 85
          plot(xval(sel), zval(sel), 'b');

        Error in ==> fieldtrip\private\artifact_viewer at 41
            read_and_plot(h);

        Error in ==> artifact_zvalue at 254
              artifact_viewer(cfg, cfg.artfctdef.zvalue, zsum, artval, zindx);

        Error in ==> artifact_eog at 126
          [tmpcfg, artifact] = artifact_zvalue(tmpcfg);

        Error in ==> rejectartifact at 197
          cfg = feval(sprintf('artifact_%s', cfg.artfctdef.type{type}), cfg);
         
The problem comes from the variable sel that is used for indexing which contains fractions:        
>> sel = trlpadsmp:(length(data)-trlpadsmp);        
>> plot(xval(sel), zval(sel), 'b');

cfg.artfctdef.eog.trlpadding default = 0.5
if the sampling frequency is not a nice round number (e.g. 625)
>> trlpadsmp = artcfg.trlpadding*hdr.Fs; will result in an error

Second, is it possible to reject pieces of data with rejectartifact that are deviant over a group of channels? For example, if I wanted to use the
temporal channels to throw out eye blinks, can I specify a group of channels and reject data pieces on the basis of some sort of composite
z-score instead of checking data channel by channel?

Thanks, greetings Jasper
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20060816/27599cc6/attachment-0001.html>


More information about the fieldtrip mailing list