[FieldTrip] Warning about fixed orientation in source localisation using DICS

Britta Westner britta.wstnr at gmail.com
Mon Mar 13 15:24:36 CET 2023


Hi Alice,

FieldTrip is telling you that once it applies a pre-computed filter (as per
your last two lines of code), it cannot guarantee you to apply weight
normalization or a fixed orientation constraint, as this depends on how you
computed your pre-computed filter (the one you call sourceAll).
For your code this is fine - it happens because you feed the same cfg
structure to ft_sourceanalysis when you apply the filter as you do when
computing it - and FieldTrip warns you that it is not doing anything with
those options this time around (i.e., when applying it).

Hope this helps,
Britta

On Mon, Mar 13, 2023 at 3:17 PM DREW , ALICE ALEXANDRA via fieldtrip <
fieldtrip at science.ru.nl> wrote:

> Hello,
>
> I am performing source localisation on EEG data using DICS. I am using the
> latest version of fieldtrip (20230309). In my analysis, I am contrasting
> two time windows of interest and I use the parameter:
> cfg.dics.fixedori ='yes';
>
> However, when running the analysis the following Warning appears in my
> command window which indicates that this parameter is not being used.
>
> "Warning: with precomputed spatial filters a fixed orientation constraint
> or weight normalization options are not applied"
>
> Does anyone know what may be causing this? Here is my code:
> %% Windows of interest
> cfg = [];
> cfg.toilim = [-0.5 0];
> cfg.keepsampleinfo='no';
> dataPre = ft_redefinetrial(cfg, data);
> cfg.toilim = [0.19 0.69];
> dataPost = ft_redefinetrial(cfg, data);
> dataAll = ft_appenddata([], dataPre, dataPost);
> %% Frequency analysis
> cfg = [];
> cfg.method = 'mtmfft';
> cfg.output = 'powandcsd';
> cfg.taper = 'hanning';
> cfg.foilim = [5 7];
> cfg.pad = 1;
> freqPre = ft_freqanalysis(cfg, dataPre);
> freqPost = ft_freqanalysis(cfg, dataPost);
> freqAll = ft_freqanalysis(cfg, dataAll);
> %% Average over frequencies
> cfg=[];
> cfg.avgoverfreq = 'yes';
> freqPre = ft_selectdata(cfg, freqPre);
> freqPost = ft_selectdata(cfg, freqPost);
> freqAll = ft_selectdata(cfg, freqAll);
> % Source reconstruction for all trials
> cfg=[];
> cfg.method='dics';
> cfg.headmodel=vol;
> cfg.dics.keepfilter = 'yes';
> cfg.dics.lambda = '5%';
> cfg.dics.fixedori ='yes';
> cfg.dics.realfilter = 'yes';
> cfg.sourcemodel = grid;
> cfg.dics.projectnoise = 'yes';
> cfg.sourcemodel.leadfield = grid.leadfield;
> sourceAll=ft_sourceanalysis(cfg, freqAll);
> % DICS for each condition using the common filter
> cfg.sourcemodel.filter = sourceAll.avg.filter;
> sourcePre=ft_sourceanalysis(cfg, freqPre);
> sourcePost=ft_sourceanalysis(cfg, freqPost);
>
> Thank you in advance!
> All the best,
> Alice
> _______________________________________________
> fieldtrip mailing list
> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
> https://urldefense.com/v3/__https://doi.org/10.1371/journal.pcbi.1002202__;!!HJOPV4FYYWzcc1jazlU!8jFHtnxMnfPWdZwpuffE0CmZYO-BE7E-lIbrkAzeppz0geMAjX93uIkmJgmuhjORrLpc2wFQ9IAYQ0HLfKZu9E8VzSE$ 
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20230313/c9b23247/attachment.htm>


More information about the fieldtrip mailing list