[FieldTrip] Maxfilter and PCA

Lorenzo Magazzini magazzinil at gmail.com
Mon Sep 19 15:00:11 CEST 2016


Hi Jan-Mathijs,

Thanks for your answer.

Just for clarity also to the other users, am I right to say that my
previous interpretation was wrong, then? Is the purpose of the PCA simply
that of 'stabilizing' the data matrix? The number of components has nothing
to do with the rank deficiency (or what is the relationship between the
two)?

Thanks,
Lorenzo



Lorenzo Magazzini

PhD Student

magazzinil at cardiff.ac.uk


CUBRIC Building
Maindy Road

Cardiff
CF24 4HQ



On 19 September 2016 at 13:45, Schoffelen, J.M. (Jan Mathijs) <
jan.schoffelen at donders.ru.nl> wrote:

> Hi all,
>
> The reason to do the PCA has to do in this context with the fact that a
> beamformer is used further down in the tutorial. The beamformer uses the
> inverse of the covariance matrix, which behaves unpredictably (but usually
> quite bad) when the smallest (usually poorly conditioned) components are
> not well estimated.
> The data that is used for the source reconstruction comes from three
> separate runs, each of which was separately maxfiltered. As a consequence,
> the low-rank subspace that is spanned by the individual runs’ data is
> slightly different (each of which has approximately, say, a rank of 60).
> Upon concatenation, however, the rank is suddenly increased to >> 60, where
> most likely quite a lot of the ‘higher’ components represent noise. In
> order to account for that in the covariance inversion, the whole data
> matrix is ‘stabilized’ with a PCA.
>
> Best,
> Jan-Mathijs
>
>
> On 19 Sep 2016, at 13:48, Lorenzo Magazzini <magazzinil at gmail.com> wrote:
>
> Hi Mike,
>
> This is a question that I've been asking myself too and I'd love to hear
> an expert (and more technical) answer. In the meantime, these discussions
> may be of help:
>
> https://mailman.science.ru.nl/pipermail/fieldtrip/2013-March/006270.html
> https://mailman.science.ru.nl/pipermail/fieldtrip/2013-
> November/007170.html
> http://www.fieldtriptoolbox.org/faq/why_does_my_ica_
> output_contain_complex_numbers?s[
>
> I wonder if the confusion arises from the difference between rank and
> number of components? My understanding is that maxfilter reduces the rank
> of the data (from 306 to 64, apparently). Therefore, my best guess is that
> by performing a PCA and rejecting a number of components (only the first 50
> are kept, in the tutorial example), the data is no longer rank-deficient,
> i.e. the rank is equal or greater than the number of components in the data.
>
> Clearly, this is a very non-technical interpretation, and a correction
> would be more than welcome.. :)
>
> Best,
> Lorenzo
>
>
>
>
>
> Lorenzo Magazzini
> PhD Student
> magazzinil at cardiff.ac.uk
>
> CUBRIC Building
> Maindy Road
> Cardiff
> CF24 4HQ
>
>
> On 19 September 2016 at 11:25, Hall, Michael (Research Student) <
> hallmbh at aston.ac.uk> wrote:
>
>> Dear All,
>>
>> I've been doing some testing with elekta neuromag data in Fieldtrip using
>> different sensor types (meg, meggrad, megmag) and different preprocessing
>> steps (tSSS 0.9 corr limit, no tSSS).
>>
>> A step that was proposed at the MEG UK 2015 demo was to use PCA to
>> compensate for the ill-conditioned estimate of the cov/csd matrix due to
>> maxfilter - could I ask why running a PCA and reducing the number of
>> components further would compensate for this? Apologies if this a naive
>> question, however I would assume that you would not want to reduce the rank
>> of your data further? Please see below for the link and code that I'm
>> referring to.
>>
>> http://www.fieldtriptoolbox.org/workshop/meg-uk-2015/fieldtr
>> ip-beamformer-demo
>>
>>
>> %% deal with maxfilter
>>
>> % the data has been maxfiltered and subsequently concatenated
>> % this results in an ill-conditioned estimate of covariance or CSD
>>
>> cfg = [];
>> cfg.method = 'pca';
>> cfg.updatesens = 'no';
>> cfg.channel = 'MEGMAG';
>> comp = ft_componentanalysis(cfg, data);
>>
>> cfg = [];
>> cfg.updatesens = 'no';
>> cfg.component = comp.label(51:end);
>> data_fix = ft_rejectcomponent(cfg, comp);
>>
>>
>> Many thanks,
>> Mike Hall
>>
>>
>>
>>
>> _______________________________________________
>> fieldtrip mailing list
>> fieldtrip at donders.ru.nl
>> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>>
>
> _______________________________________________
> fieldtrip mailing list
> fieldtrip at donders.ru.nl
> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>
>
>
>
>
>
> _______________________________________________
> fieldtrip mailing list
> fieldtrip at donders.ru.nl
> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160919/48694aad/attachment-0002.html>


More information about the fieldtrip mailing list