[FieldTrip] problem with ft_rejectartifact

Ayelet Landau ayelet.landau at gmail.com
Tue Sep 4 13:23:21 CEST 2012


Dear FieldTrip experts,

I have encountered a strange behavior in ft_rejectartifact script.

artifacts are defined in variables that contain two collumns and fed into
this function as follows:
         cfg.artfctdef.eog.artifact =artifact_eog_all;

other parameters I use are:
   cfg.trl=trl;
        cfg.artfctdef.reject = 'partial';
        cfg.artfctdef.minaccepttim  = .2;

then I run ft_rejectartifact with this cfg (and many more categories of
artifacts as exemplified above) and a structure containing my preprocessed
data (with a the same trl I give in cfg.trl above). This is an example of
what the data structure fed into ft_rejectartifact might looks like

          hdr: [1x1 struct]
       fsample: 1200
          grad: [1x1 struct]
    sampleinfo: [50x2 double]
     trialinfo: [50x4 double]
         trial: {1x50 cell}
          time: {1x50 cell}
         label: {275x1 cell}
           cfg: [1x1 struct]

and here is the error that I get:

??? Subscripted assignment dimension mismatch.

Error in ==> ft_redefinetrial at 253
      data.trialinfo(iTrl,:) = dataold.trialinfo(iTrlorig,:);

Error in ==> ft_rejectartifact at 483
    data       = ft_redefinetrial(tmpcfg, data);

When I run ft_rejectartifact with a cfg.data field calling my *.ds file, I
get the following which I could probably use later as an adjusted trl for
ft_preprocessing:
       datafile: 'XX_20120821_05.ds'
             trl: [79x7 double]
       artfctdef: [1x1 struct]
     trackconfig: 'off'
     checkconfig: 'loose'
       checksize: 100000
    showcallinfo: 'yes'
      headerfile: 'XX_20120821_05.ds'
          trlold: [50x7 double]
        callinfo: [1x1 struct]
         version: [1x1 struct]

Its a bit strange that my original approach stopped working. Any insights
most welcome!

-- 
Ayelet N. Landau

Postdoctoral Scientist,
Ernst Strüngmann Institute (ESI) for Neuroscience
in Cooperation with Max Planck Society
Deutschordenstr. 46, D-60528 Frankfurt

Mobile:      +49 (0)16 22733 110
Fax:      +49 (0)69 96769 555
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20120904/aa339f00/attachment-0001.html>


More information about the fieldtrip mailing list