[FieldTrip] Problem in ft_timelockstatistics() phase

Sander Maijers S.N.Maijers at student.ru.nl
Sat Apr 28 16:01:25 CEST 2012


Hi,

I am trying to rework a small FieldTrip experiment I did last year (reproduction of larger experiment done by Irina Simanova).

Calling ft_timelockstatistics() on two ERP data partitions results in an error: "Undefined function 'fieldnames' for input arguments of type 'cell'." I'm running FieldTrip under MATLAB R2011b 64-bit on Linux.

I see a possible cause of the problem, in that these data we pre-analysed with ft_timelockanalysis() a year ago, or longer. I read them from parts of the data set I was supplied with. Maybe there have been breaking changes to this function in the meantime? The cfg struct that I pass as parameter seems in line with the current documentation, though.


LOG:

>> main()

data_set_location =

/media/SAMSUNG/0,data_set/EEG/0 MATLAB


output_dir =

/tmp/EEG

Data set part file: timelock10_lp
Data set part file: timelock11_lp

CONTRAST 
[class 1, size = 220]: participant timelock10_lp on condition avg_anm_aud_lp 
[class 2, size = 224]: participant timelock10_lp on condition avg_tls_aud_lp
cfg
     method: 'crossvalidate'
    latency: [0 0.7000]
    channel: {1x60 cell}
     nfolds: 5
        mva: {2x1 cell}
     design: [444x1 double]

class_1_data__struct
        avg: [62x501 double]
        var: [62x501 double]
    fsample: 500
       time: [1x501 double]
        dof: [62x501 double]
      label: {62x1 cell}
      trial: [220x62x501 double]
     dimord: 'rpt_chan_time'
        cfg: [1x1 struct]

class_2_data__struct
        avg: [62x501 double]
        var: [62x501 double]
    fsample: 500
       time: [1x501 double]
        dof: [62x501 double]
      label: {62x1 cell}
      trial: [224x62x501 double]
     dimord: 'rpt_chan_time'
        cfg: [1x1 struct]

selected 60 channels
selected 351 time bins
selected 1 frequency bins
using "ft_statistics_crossvalidate" for the statistical testing
fixing random number generator for reproducibility
creating sample indices using 5-fold cross-validation
validating fold 1 of 5 for 1 datasets
validating fold 2 of 5 for 1 datasets
validating fold 3 of 5 for 1 datasets
validating fold 4 of 5 for 1 datasets
validating fold 5 of 5 for 1 datasets
Undefined function 'fieldnames' for input arguments of type 'cell'.

Error in ft_statistics_crossvalidate (line 84)
fn = fieldnames(stat.model{1});

Error in statistics_wrapper (line 298)
    [stat] = statmethod(cfg, dat, design);

Error in ft_timelockstatistics (line 110)
[stat, cfg] = statistics_wrapper(cfg, varargin{:});

Error in main/modeling (line 203)
        stat = ft_timelockstatistics(cfg, class_1_datastruct, class_2_datastruct);

Error in main/statistics (line 225)
            stat = modeling(data_set, method, obj_class_1_and_2);

Error in main/ERP_experiment (line 374)
            stats = statistics(data_set, contrasts, method);

Error in main (line 401)
    stats_x = ERP_experiment(data_set_location, 'RR', output_dir)


Any suggestions would be welcom!

Kind regards,
Sander Maijers



More information about the fieldtrip mailing list