[FieldTrip] Error in ft_mvaranalysis

Schoffelen, J.M. (Jan Mathijs) jan.schoffelen at donders.ru.nl
Fri Aug 31 11:32:43 CEST 2018


Dear Manuela,

This looks like a typo in the code, which I will fix (and once fixed will become available in the daily release version of the code). To give myself some time: probably not tonight, but perhaps after the weekend :). However, the fact that this part of the code clearly doesn’t work, I am not entirely sure whether the rest will work smoothly as well, as soon as the current hurdle is fixed. But let’s see

Best wishes,
Jan-Mathijs


On 29 Aug 2018, at 13:34, Manuela Costa <manuela.costa at ctb.upm.es<mailto:manuela.costa at ctb.upm.es>> wrote:

Dear community,

I'm planning to do granger causality analysis on human iEEG data. I'm using ft_mvaranalysis to get time-dependent coefficient sets based on a sliding window, but I get an error.

The data is downsampled at 250 Hz. The fields of my data structure are fsample, trial, time, label and cfg. The size of preprocessing_emotional_Rem_ds{1}.trial{1} is 3x3751 (channels, data points). Below is the configuration structure and the error message. The ft_mvaranalysis function works if I do not use the sliding window approach. I tried to use different cfg.toi and cfg.t_ftimwin but I could not find a solution. I hope you can help me.

Best wishes,

Manuela Costa

Configuration structure:

cfg = [];
    cfg.toolbox = 'bsmart';
    cfg.order   = 10;
    cfg.toi       = -0.5:0.01:3; %% the time points at which the windows are centered
    cfg.t_ftimwin = 0.25; %% length of time window in second
    mdata_emotional_Rem{subj} = ft_mvaranalysis(cfg, preprocessing_emotional_Rem_ds{subj});




Error message:


Matrix dimensions must agree.

Error in ft_mvaranalysis (line 185)
latency(k,:) = cfg.toi + cfg.t_ftimwin.*[-0.5 0.5];

Error in Step2_Calculate_Granger_time_freq(line 108)
    mdata_emotional_Rem{subj} = ft_mvaranalysis(cfg,preprocessing_emotional_Rem_ds{subj});



_______________________________________________
fieldtrip mailing list
https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
https://doi.org/10.1371/journal.pcbi.1002202

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20180831/8f149de0/attachment-0002.html>


More information about the fieldtrip mailing list