Back to the main page.

Bug 665 - ft_definetrial / trialfun_general fails

Status CLOSED FIXED
Reported 2011-05-13 09:12:00 +0200
Modified 2011-06-06 10:18:45 +0200
Product: FieldTrip
Component: core
Version: unspecified
Hardware: All
Operating System: All
Importance: P1 critical
Assigned to: Robert Oostenveld
URL:
Tags:
Depends on:
Blocks:
See also:

Andreas Wollbrink - 2011-05-13 09:12:21 +0200

Trying to read in our own data (275 channel CTF MEG system) or even the tutorial data the function ft_definetrial fails. After checking several versions of fieldtrip I realized that in version fieldtrip-20110510 the bug does not exist. For all later versions (20110511 / 20110512) the functions fails using the following code (taken fromm the tutorial): %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% cfg = []; cfg.dataset = 'Subject01.ds'; cfg.trialdef.eventtype = 'backpanel trigger'; cfg.trialdef.eventvalue = 3; % the value of the stimulus trigger for fully incongruent (FIC). cfg.trialdef.prestim = 1; % in seconds cfg.trialdef.poststim = 2; % in seconds cfg = ft_definetrial(cfg); %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% The error message is the following: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ??? Error using ==> and Inputs must have the same size. Error in ==> trialfun_general at 121 sel = sel & ismember({event.type}, cfg.trialdef.eventtype); Error in ==> ft_definetrial at 140 [trl, event] = feval(cfg.trialfun, cfg); %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


Robert Oostenveld - 2011-05-13 20:28:38 +0200

thanks, I just fixed it. MacBook> svn commit Sending trialfun/trialfun_general.m Transmitting file data . Committed revision 3541. please get the latest versiopn with the update this evening from the ftp or from http://code.google.com/p/fieldtrip


Robert Oostenveld - 2011-06-06 10:18:45 +0200

closed several bugs at once