[Mne_analysis] equivalence of averaged single trial STCs and evoked STCs

Hari Bharadwaj hari at nmr.mgh.harvard.edu
Fri Mar 14 16:21:22 EDT 2014
Search archives:

Also, just wanted to quickly add that in my understanding, what dSPM is
essentially trying to achieve is the same kind of normalization as would
result when you do MNE first and then scale by the baseline.. So those
results (i.e., MNE and then normalize by baseline  Vs. dSPM) should be
very similar, especially if the same baseline period is used for
calculating the noise covariance matrix.

On Fri, March 14, 2014 4:11 pm, Hari Bharadwaj wrote:
> Hi Tal et al.,
>     Just some thoughts.. Feel free to pick them apart:
>
> Combining the three components (rather than picking the normal component
> only) using a norm calculation is a non-linear operation that changes
> things and it matters whether you do normalization first or whether you
> combine components first... This is related to the discussion in issue
> #962:
> https://github.com/mne-tools/mne-python/issues/962
>
> Also, I don't think there is a good way to come with a "standard"
> recommendation for single trial data which is general enough.. A lot would
> depend on what the subsequent use is (and possibly processing history, eg:
> what data you used to estimate the noise-covariance matrix).
>
> That said, if you are interested in time-courses, rather than spatial
> maps, then using any of the three should be OK. Indeed, for measures that
> depend only on the time course and not scaling (like coherence for
> example), you should get identical results for MNE/dSPM/sLORETA and
> regardless of how you baseline normalize.
>     I personally have never used free orientation solutions (i.e., I have
> always used fixed or pick=normal).. This is partly because I cannot
> think of any good way to combine the components and still be able to
> do spectral/time-series analyses after that. Others with more
> experience here may have better insight.
>
> Hari
>
>
>
>
>
>
>
> On Fri, March 14, 2014 1:37 pm, Tal Linzen wrote:
>> To revive this thread: Denis, in the PDF you posted, the averaged then
>> transformed data still looks different from the transformed then
>> averaged
>> data if pick_ori is set to None. What's causing this?
>>
>> Re baseline correcting, so the general recommendation when working with
>> single-trial data is to use MNE rather than dSPM, then normalize each
>> epoch
>> individually (explicitly, subtract the mean of the baseline from the
>> whole
>> epoch, then divide the whole epoch by the standard deviation of the
>> baseline)?
>>
>> On Mon, Mar 10, 2014 at 6:32 PM, Matti Hamalainen
>> <msh at nmr.mgh.harvard.edu>wrote:
>>
>>> Note: MNE does not change with nave, the others do - Matti
>>>
>>> > On Mar 10, 2014, at 17:30, "Hari Bharadwaj"
>>> <hari at nmr.mgh.harvard.edu>
>>> wrote:
>>> >
>>> > Hi Denis,
>>> >
>>> > Just some thoughts..
>>> >
>>> > Your observations about post hoc normalization make sense:
>>> > When looking at a single vertex over time or frequency, MNE, dSPM,
>>> > sLORETA, etc. are just scaled versions of each other (i.e., by a
>>> constant
>>> > scalar factor).. The effect of changing 'nave' (which is what is
>>> different
>>> > between your apply_inverse and apply_inverse_epochs cases) would also
>>> only
>>> > affect the scaling factor with the time course itself intact...Thus,
>>> when
>>> > you normalize within vertex post hoc, they become the same once
>>> again..
>>> >
>>> > *However*, when looking *across sources*, this constant scale factor
>>> for
>>> > each source would be different (which of course is the basis for the
>>> > improved resolution of dSPM and sLORETA over MNE).. So if you are
>>> looking
>>> > at spatial maps AND projecting single trials, it may be useful to
>>> > explicitly set nave to n_epochs even in the single trial case..
>>> >
>>> > Thoughts?
>>> >
>>> > Hari
>>> >
>>> >> On Mon, March 10, 2014 4:36 pm, Denis-Alexander Engemann wrote:
>>> >> Hi Hari,
>>> >>
>>> >> the 'nave' parameter is supposed to be 'n_epochs' in the evoked case
>>> and 1
>>> >> in the single trial case.
>>> >>
>>> >> It seems, post-hoc normalizing to the baseline does the trick, as
>>> >> suspected:
>>> >>
>>> >>
>>> https://www.dropbox.com/s/kugvns9klfqhu2z/methods_comparison_evoked_single_trial.pdf
>>> >>
>>> >> once more, gist updated: https://gist.github.com/dengemann/9470121
>>> >>
>>> >> What do people think?
>>> >>
>>> >> Best,
>>> >> Denis
>>> >>
>>> >>
>>> >>
>>> >> On Mon, Mar 10, 2014 at 8:42 PM, Hari Bharadwaj
>>> >> <hari at nmr.mgh.harvard.edu>wrote:
>>> >>
>>> >>> Also, it might be interesting to see what the default 'nave's are
>>> >>> apply_inverse() and apply_inverse_epochs() and what implications
>>> that
>>> >>> might have..
>>> >>>
>>> >>>
>>> >>>> On Mon, March 10, 2014 3:26 pm, Denis-Alexander Engemann wrote:
>>> >>>> [reposted, attachment failure]
>>> >>>>
>>> >>>> Hi Dan,
>>> >>>>
>>> >>>> that was indeed a very good hint.
>>> >>>>
>>> >>>> I've updated the gist to do some more systematic comparisons
>>> between
>>> >>>> orientations and methods:
>>> >>>>
>>> >>>> https://gist.github.com/dengemann/9470121
>>> >>>>
>>> >>>> As to you clarification questions, the lines referred to in the
>>> legend
>>> >>> as
>>> >>>> 'single*' are related to averaging in source space.
>>> >>>>
>>> >>>> It seems using MNE and with a post-hoc normalization, e.g. using
>>> >>> z-scores
>>> >>>> might be the way to go.
>>> >>>>> From my ad-hoc parameter experiment I cannot exclude the
>>> possibility,
>>> >>>>> that
>>> >>>> 'dSPM' and 'sLORETA' with 'normal' orientation might work as well.
>>> >>>> This would require a mean-flip method though which is not
>>> implemented
>>> >>> in
>>> >>>> my
>>> >>>> script due to the manual extraction used.
>>> >>>> My extraction function, here, was `lambda x: np.abs(x).mean(0)`
>>> >>>>
>>> >>>> This needs more investigation + discussion
>>> >>>>
>>> >>>> Denis
>>> >>>>
>>> >>>>
>>> >>>> Images:
>>> >>>>
>>> >>>> https://www.dropbox.com/s/e4ykrm6xdh6ntio/fig-None-MNE.png
>>> >>>>
>>> >>>> https://www.dropbox.com/s/qwlt5ugxxo0owo2/fig-normal-MNE.png
>>> >>>>
>>> >>>> https://www.dropbox.com/s/mijmz9pvffgt5ms/fig-None-sLORETA.png
>>> >>>>
>>> >>>> https://www.dropbox.com/s/8dxf0czptuhyybs/fig-normal-sLORETA.png
>>> >>>>
>>> >>>> https://www.dropbox.com/s/hxcjla8x9euwzd3/fig-None-dSPM.png
>>> >>>>
>>> >>>> https://www.dropbox.com/s/e5pbr7iyday3za4/fig-normal-dSPM.png
>>> >>>>
>>> >>>>
>>> >>>>
>>> >>>>
>>> >>>>> On Mon, Mar 10, 2014 at 7:13 PM, dgw <dgwakeman at gmail.com> wrote:
>>> >>>>>
>>> >>>>> Hi Denis,
>>> >>>>>
>>> >>>>> Which line represents "averaging in source space" and which
>>> >>> represents
>>> >>>>> "projecting evokeds"?
>>> >>>>>
>>> >>>>> Regardless. I think you are referring to why are the results
>>> >>> different
>>> >>>>> when I average single trial data on the source space as opposed
>>> to
>>> >>>>> averaging that same data in sensor space and then source
>>> localizing?
>>> >>>>>
>>> >>>>> The first reason I can think of is that you are using the dSPM
>>> here
>>> >>> and
>>> >>>>> I
>>> >>>>> believe that that can lead to some non-linearity between these
>>> >>> results.
>>> >>>>> Do
>>> >>>>> you get the same problem with the L2?
>>> >>>>>
>>> >>>>> HTH,
>>> >>>>> D
>>> >>>>>
>>> >>>>>
>>> >>>>> On Mon, Mar 10, 2014 at 1:56 PM, Denis-Alexander Engemann <
>>> >>>>> denis.engemann at gmail.com> wrote:
>>> >>>>>
>>> >>>>>> Hi folks,
>>> >>>>>>
>>> >>>>>> in one of my recent analyses I ran into some problems with
>>> regard
>>> to
>>> >>>>>> morphing and single trial
>>> >>>>>> label time series extraction which lead me to set up some
>>> >>> comparisons:
>>> >>>>>>
>>> >>>>>> https://gist.github.com/dengemann/9470121
>>> >>>>>>
>>> >>>>>> (gist based on sample data, should run with a proper MNE-Python
>>> >>>>>> install)
>>> >>>>>>
>>> >>>>>> [image: Inline image 1]
>>> >>>>>>
>>> >>>>>> It turned out morphing was unproblematic, but,
>>> >>>>>> I'm wondering whether the differences between averaging in
>>> source
>>> >>> space
>>> >>>>>> and
>>> >>>>>> projecting evokeds is expected, and if so, how it can be
>>> avoided?
>>> >>>>>>
>>> >>>>>> The background is that I'd like to be confident about the
>>> relating
>>> >>>>>> single
>>> >>>>>> trial analyses at the evoked level.
>>> >>>>>>
>>> >>>>>> Any thoughts?
>>> >>>>>>
>>> >>>>>> Cheers,
>>> >>>>>> Denis
>>> >>>>>>
>>> >>>>>>
>>> >>>>>>
>>> >>>>>>
>>> >>>>>> _______________________________________________
>>> >>>>>> Mne_analysis mailing list
>>> >>>>>> Mne_analysis at nmr.mgh.harvard.edu
>>> >>>>>> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
>>> >>>>>>
>>> >>>>>>
>>> >>>>>> The information in this e-mail is intended only for the person
>>> to
>>> >>> whom
>>> >>>>>> it
>>> >>>>>> is
>>> >>>>>> addressed. If you believe this e-mail was sent to you in error
>>> and
>>> >>> the
>>> >>>>>> e-mail
>>> >>>>>> contains patient information, please contact the Partners
>>> Compliance
>>> >>>>>> HelpLine at
>>> >>>>>> http://www.partners.org/complianceline . If the e-mail was sent
>>> to
>>> >>> you
>>> >>>>>> in error
>>> >>>>>> but does not contain patient information, please contact the
>>> sender
>>> >>> and
>>> >>>>>> properly
>>> >>>>>> dispose of the e-mail.
>>> >>>> _______________________________________________
>>> >>>> Mne_analysis mailing list
>>> >>>> Mne_analysis at nmr.mgh.harvard.edu
>>> >>>> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
>>> >>>
>>> >>>
>>> >>> --
>>> >>> Hari Bharadwaj
>>> >>> PhD Candidate, Biomedical Engineering,
>>> >>> Boston University
>>> >>> 677 Beacon St.,
>>> >>> Boston, MA 02215
>>> >>>
>>> >>> Martinos Center for Biomedical Imaging,
>>> >>> Massachusetts General Hospital
>>> >>> 149 Thirteenth Street,
>>> >>> Charlestown, MA 02129
>>> >>>
>>> >>> hari at nmr.mgh.harvard.edu
>>> >>> Ph: 734-883-5954
>>> >
>>> >
>>> > --
>>> > Hari Bharadwaj
>>> > PhD Candidate, Biomedical Engineering,
>>> > Boston University
>>> > 677 Beacon St.,
>>> > Boston, MA 02215
>>> >
>>> > Martinos Center for Biomedical Imaging,
>>> > Massachusetts General Hospital
>>> > 149 Thirteenth Street,
>>> > Charlestown, MA 02129
>>> >
>>> > hari at nmr.mgh.harvard.edu
>>> > Ph: 734-883-5954
>>> >
>>> >
>>> > _______________________________________________
>>> > Mne_analysis mailing list
>>> > Mne_analysis at nmr.mgh.harvard.edu
>>> > https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
>>> >
>>> >
>>>
>>> _______________________________________________
>>> Mne_analysis mailing list
>>> Mne_analysis at nmr.mgh.harvard.edu
>>> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
>>>
>>
>
>
> --
> Hari Bharadwaj
> PhD Candidate, Biomedical Engineering,
> Boston University
> 677 Beacon St.,
> Boston, MA 02215
>
> Martinos Center for Biomedical Imaging,
> Massachusetts General Hospital
> 149 Thirteenth Street,
> Charlestown, MA 02129
>
> hari at nmr.mgh.harvard.edu
> Ph: 734-883-5954
>
>
> _______________________________________________
> Mne_analysis mailing list
> Mne_analysis at nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
>
>
>


-- 
Hari Bharadwaj
PhD Candidate, Biomedical Engineering,
Boston University
677 Beacon St.,
Boston, MA 02215

Martinos Center for Biomedical Imaging,
Massachusetts General Hospital
149 Thirteenth Street,
Charlestown, MA 02129

hari at nmr.mgh.harvard.edu
Ph: 734-883-5954





More information about the Mne_analysis mailing list