[FieldTrip] ft_databrowser error

Carmen Kung carmen.kung at mq.edu.au
Wed Jul 27 08:01:40 CEST 2016

Dear fieldtripers,

After running ft_definetrial and ft_preprocessing, we try to plot the 
data using ft_databrowser using the script at follow:

 >> cfg = [];
 >> ft_databrowser(cfg, data);

But this is the error message we got:

the input is raw data with 69 channels and 25 trials
detected   0 visual artifacts
Error using zeros
Size inputs must be integers.

Error in convert_event>artifact2artvec (line 179)
artvec = zeros(length(artifact), endsample);

Error in convert_event (line 103)
     obj = artifact2artvec(obj,endsample);

Error in ft_databrowser (line 501)
artdata.trial{1}       = convert_event(artifact, 'boolvec', 'endsample', 
datendsample); % every artifact is a "channel"

We did try to plot the raw *.cnt file (the cnt is recorded using curry 
7) using ft_databrowser. It worked, but not the epoched data. This is 
the parameters we used for the cfg to run ft_definetrial and 

     cfg = [];
     cfg.dataformat = 'ns_cnt';
     cfg.headerformat= 'ns_cnt';
     cfg.eventformat= 'ns_cnt';
     cfg.trialdef.eventtype = 'stimtype';
     cfg.trialdef.prestim = 0.5;
     cfg.trialdef.poststim = 1.5;
     cfg.trialdef.eventvalue = 114;
     cfg.dataset = [dir filesep 'cnt' filesep subjectdata.subjectnr '_' 
subjectdata.initial '_' subjectdata.date '.cnt'];
     cfg = ft_definetrial(cfg);
     data = ft_preprocessing(cfg);

The analysis is run on fieldtrip-20150522 and Matlab 2014a. Any help 
with this will be appreciated!

Many thanks in advance,

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160727/6df4adac/attachment-0001.html>

More information about the fieldtrip mailing list