[FieldTrip] Different way of calculating the covariance for LCM
Yuval Harpaz
yuvharpaz at gmail.com
Wed Mar 23 10:42:11 CET 2011
I checked it again, I used a data structure 'D1st' which included 90 trials.
I ran the following script and the result was a 'pre' structure. field
pre.cov was a 90*248*248 matrix, i.e., the covariance was estimated for all
the trials.
cfg = [];
cfg.covariance = 'yes';
cfg.removemean = 'no';
cfg.covariancewindow = [-0.1 0];
cfg.channel='MEG';
cfg.keeptrials = 'yes' ;
pre=ft_timelockanalysis(cfg, D1st);
you may find this script repository useful for LCMV analysis. it includes an
older version of fieldtrip but this is the one we work with.
http://yuval-harpaz.github.com/ft_BIU/
check the actual repository here (read the README) :
https://github.com/yuval-harpaz/ft_BIU
good luck there, yuval.
On 23 March 2011 10:42, Jean-Michel Badier <jean-michel.badier at univmed.fr>wrote:
> Thanks Yuval,
>
>
> Le 22/03/11 10:55, Yuval Harpaz a écrit :
>
> So just run the commands on an unaveraged dataset.
>
> Yes but that would be correct if there was only one trial in the data set
> (see the message from Luisa).
>
>
> Another option to consider is the one used by Dr. Robinson when
> performing SAMerf (we have his tool here<http://yuval-harpaz.github.com/SAM_BIU/>,
> works for our 4D machine).
>
>
> Thanks for it I will test it.
>
> The idea is to calculate the covariance on all trials, calculate weights
> by this covariance (keep filter in LCMV) and then apply these weights on the
> averaged data. I found it useful because the covariance is better for longer
> datasets, and the averaging in the end increases the signal to noise ratio.
> I do not know exactly how to do it in fieldtrip.
>
> On 22 March 2011 10:43, Jean-Michel Badier <jean-michel.badier at univmed.fr>wrote:
>
>> Dear Yuval,
>>
>> I have to admit that I did not look at the matlab routines.
>> In item 2 I suppose that the covariance is calculated for each trial then
>> averaged. In item 3 I would like to calculate the covariance from all the
>> signal (the trials being concatenated).
>>
>> Jean-Michel
>>
>> Le 22/03/11 05:47, Yuval Harpaz a écrit :
>>
>> Dear Jean Michel
>> As far as I know you can do it on an averaged data structure (item 1) or
>> do the same with the data structure before averaging (3). I did not
>> understand what you meant by 2.
>>
>> Yuval
>>
>> On 21 March 2011 22:58, Jean-Michel Badier <jean-michel.badier at univmed.fr
>> > wrote:
>>
>>> Dear fieldtrip users,
>>>
>>> There are different ways of estimating the covariance for LCMV
>>> calculation.
>>> If I am correct:
>>>
>>> 1. As suggested in one of the tutorial one can apply the calculation of
>>> the covariance directly on the average data (for the different periods of
>>> interest that are at least a base line and the period of interest).
>>>
>>> 2. Estimate the covariance from the average of the covariance rather than
>>> the covariance of the average using cfg.keeptrials = "yes"
>>>
>>> 3. Estimate the covariance from the whole trials concatenated together.
>>> Is there an easy way to do that in fieldtrip (beside create a new data
>>> set of one trial constituted of all the trials)?
>>>
>>> Thanks
>>>
>>> Jean-Michel
>>>
>>> -- Jean-Michel Badier PhD
>>> Laboratoire de MagnétoEncéphaloGraphie INSERM U751. Aix
>>> Marseille Université 33 (0)4 91 38 55 62 *jean-michel.badier at univmed.fr
>>> * <jean-michel.badier at univmed.fr>
>>> Service de Neurophysiologie Clinique. CHU Timone 264 Rue
>>> Saint-Pierre, 13005 Marseille-France
>>>
>>>
>>>
>>> _______________________________________________
>>> fieldtrip mailing list
>>> fieldtrip at donders.ru.nl
>>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>>>
>>
>>
>>
>> --
>> Y.Harpaz
>>
>> a link to the BIU MEG lab:
>> http://faculty.biu.ac.il/~goldsa/index.html
>>
>> " Why, Dan," ask the people in Artificial Intelligence, "do you waste
>> your time conferring with those neuroscientists? They wave their hands about
>> information processing and worry about where it happens, and
>> which neurotransmitters are involved, and all those boring facts, but
>> they haven't a clue about the computational requirements of higher
>> cognitive functions." "Why," ask the neuroscientists, "do you waste your
>> time on the fantasies of Artificial Intelligence? They just invent
>> whatever machinery they want, and say unpardonably ignorant things about the
>> brain." The cognitive psychologists, meanwhile, are accused of concocting
>> models with neither biological plausibility nor proven computational powers;
>> the anthropologists wouldn't know a model if they saw one, and the
>> philosophers, as we all know, just take in each other's laundry, warning
>> about confusions they themselves have created, in an arena bereft of both
>> data and empirically testable theories. With so many idiots working on the
>> problem, no wonder consciousness is still a mystery.* Philosopher Daniel
>> Dennet, consciousness explained, pp. 225*
>>
>>
>> _______________________________________________
>> fieldtrip mailing listfieldtrip at donders.ru.nlhttp://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>>
>>
>>
>>
>>
>> _______________________________________________
>> fieldtrip mailing list
>> fieldtrip at donders.ru.nl
>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>>
>
>
>
> --
> Y.Harpaz
>
> a link to the BIU MEG lab:
> http://faculty.biu.ac.il/~goldsa/index.html
>
> " Why, Dan," ask the people in Artificial Intelligence, "do you waste
> your time conferring with those neuroscientists? They wave their hands about
> information processing and worry about where it happens, and
> which neurotransmitters are involved, and all those boring facts, but
> they haven't a clue about the computational requirements of higher
> cognitive functions." "Why," ask the neuroscientists, "do you waste your
> time on the fantasies of Artificial Intelligence? They just invent
> whatever machinery they want, and say unpardonably ignorant things about the
> brain." The cognitive psychologists, meanwhile, are accused of concocting
> models with neither biological plausibility nor proven computational powers;
> the anthropologists wouldn't know a model if they saw one, and the
> philosophers, as we all know, just take in each other's laundry, warning
> about confusions they themselves have created, in an arena bereft of both
> data and empirically testable theories. With so many idiots working on the
> problem, no wonder consciousness is still a mystery.* Philosopher Daniel
> Dennet, consciousness explained, pp. 225*
>
>
> _______________________________________________
> fieldtrip mailing listfieldtrip at donders.ru.nlhttp://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>
>
>
> --
>
> Jean-Michel Badier
>
>
> Laboratoire de MagnétoEncéphaloGraphie
>
> INSERM U751. Aix Marseille Université
>
> 33 (0)4 91 38 55 62
>
> *jean-michel.badier at univmed.fr* <jean-michel.badier at univmed.fr>
>
>
> Service de Neurophysiologie Clinique. CHU Timone
>
> 264 Rue Saint-Pierre, 13005 Marseille-France
>
>
>
>
> _______________________________________________
> fieldtrip mailing list
> fieldtrip at donders.ru.nl
> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>
--
Y.Harpaz
a link to the BIU MEG lab:
http://faculty.biu.ac.il/~goldsa/index.html
" Why, Dan," ask the people in Artificial Intelligence, "do you waste your
time conferring with those neuroscientists? They wave their hands about
information processing and worry about where it happens, and
which neurotransmitters are involved, and all those boring facts, but
they haven't a clue about the computational requirements of higher
cognitive functions." "Why," ask the neuroscientists, "do you waste your
time on the fantasies of Artificial Intelligence? They just invent
whatever machinery they want, and say unpardonably ignorant things about the
brain." The cognitive psychologists, meanwhile, are accused of concocting
models with neither biological plausibility nor proven computational powers;
the anthropologists wouldn't know a model if they saw one, and the
philosophers, as we all know, just take in each other's laundry, warning
about confusions they themselves have created, in an arena bereft of both
data and empirically testable theories. With so many idiots working on the
problem, no wonder consciousness is still a mystery.* Philosopher Daniel
Dennet, consciousness explained, pp. 225*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20110323/f77ca037/attachment-0002.html>
More information about the fieldtrip
mailing list