From psowman at MACCS.MQ.EDU.AU  Mon Nov  1 04:28:23 2010
From: psowman at MACCS.MQ.EDU.AU (Paul Sowman)
Date: Mon, 1 Nov 2010 04:28:23 +0100
Subject: ft_megrealign
Message-ID: <MON.1.NOV.2010.042823.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi, I'd like to use ft_megrealign with our Yokagawa systems.

I get this error:

>> interp1 = ft_megrealign(cfg, data_meg)
the input is raw data with 128 channels and 1 trials
removing 128 non-MEG channels from the data
Warning: could be Yokogawa system
> In ft_senstype at 233
  In ft_megrealign at 186
??? Error using ==> ft_megrealign at 209
unsupported MEG system for realigning, please
ask on the mailing list

Is it a matter of relabeling channels?

Thanks, Paul

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From psowman at MACCS.MQ.EDU.AU  Mon Nov  1 05:19:07 2010
From: psowman at MACCS.MQ.EDU.AU (Paul Sowman)
Date: Mon, 1 Nov 2010 05:19:07 +0100
Subject: ft_megrealign
Message-ID: <MON.1.NOV.2010.051907.0100.FIELDTRIP@NIC.SURFNET.NL>

Further to my last message, we have a yokogawa 64 channel system that
doesn't seem to be supported under ft_senstype. The .con file setup is the
same and reads in ok but because the number of channels is smaller the
senstype fails. Is there a way I could work around this? 

Thanks again, Paul

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From psowman at MACCS.MQ.EDU.AU  Mon Nov  1 06:27:22 2010
From: psowman at MACCS.MQ.EDU.AU (Paul Sowman)
Date: Mon, 1 Nov 2010 06:27:22 +0100
Subject: ft_megrealign
Message-ID: <MON.1.NOV.2010.062722.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi I'd like to use ft_megrealign on my Yokogawa data however it seems that
this function doesn't currently have Yokogawa support.
I get:

>> interp1 = ft_megrealign(cfg, data_meg)
the input is raw data with 128 channels and 1 trials
removing 128 non-MEG channels from the data
Warning: could be Yokogawa system
> In ft_senstype at 233
  In ft_megrealign at 186
??? Error using ==> ft_megrealign at 209
unsupported MEG system for realigning, please
ask on the mailing list

Is there a way to work around this?

Thanks, Paul

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From lwn_07 at YAHOO.COM.CN  Mon Nov  1 16:36:17 2010
From: lwn_07 at YAHOO.COM.CN (=?utf-8?B?5p2O5Y2r5aic?=)
Date: Mon, 1 Nov 2010 23:36:17 +0800
Subject: About eeg rereference
Message-ID: <MON.1.NOV.2010.233617.0800.FIELDTRIP@NIC.SURFNET.NL>

Dear Jan and other fieldtripers,
I'm dealing with my EEG data. I want to run some cross correlation and coherence on them. The problem is:
1. which reference method will you advise me to choice? my data is reference to the vertex(Cz), i don't know whether it's ok, seems most of you choose the average between left and right mastoid.
2.IF we will do rereference,it's guided in  the m-file 'ft_preprocessing' that we might configure our inputs as
"%   cfg.reref         = 'no' or 'yes' (default = 'no')
%   cfg.refchannel    = cell-array with new EEG reference channel(s)
%   cfg.implicitref   = 'label' or empty, add the implicit EEG reference as zeros (default = [])
%   cfg.montage       = 'no' or a montage structure (default = 'no')"
then, what's the difference between "reref" and "montage"?
      Is the montage structure a matrix, and how it defines?If I modify my data to an average rereference, how will be the input configured?

Best,
Weina LI




---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101101/edeb6292/attachment.htm>

From xiaohanh at ANDREW.CMU.EDU  Mon Nov  1 18:27:22 2010
From: xiaohanh at ANDREW.CMU.EDU (Xiaohan Huang)
Date: Mon, 1 Nov 2010 13:27:22 -0400
Subject: Questions about creating template. Thank you.
Message-ID: <MON.1.NOV.2010.132722.0400.FIELDTRIP@NIC.SURFNET.NL>

Dear fieldtrip developers,

Hi. I am interested in fieldtrip. I think it is very useful.

I am now studying the example of
"read_neuromag_mri_and_create_single-subject_grids_in_individual_head_space_that_are_all_aligned_in_mni_space"
(http://fieldtrip.fcdonders.nl/example/read_neuromag_mri_and_create_single-subject_grids_in_individual_head_space_that_are_all_aligned_in_mni_space).
I notice that there is one step to set the cfg.template. I am a little
confused about this. Would you please tell me what is the usage of
template? And do we have to set template before we process the neuromag
fif data? And should this template be different from the one for .mri
file, as used in http://fieldtrip.fcdonders.nl/tutorial/beamformer?

Thank you so much,
Xiaohan

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From e.vandenbroeke at ANES.UMCN.NL  Tue Nov  2 22:23:22 2010
From: e.vandenbroeke at ANES.UMCN.NL (Emanuel van den Broeke)
Date: Tue, 2 Nov 2010 22:23:22 +0100
Subject: cluster based analysis
Message-ID: <TUE.2.NOV.2010.222322.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear dr. Maris,

Allow me to ask you one more question about the cluster-based analysis.
I have three groups but I'm only interested in two combinations:
group A versus B and 
group B versus C

Is it allowed to do two single cluster-based analyses with the above 
mentioned pairs and with a Bonferroni correction of the p-value for the two 
comparisons or is it required to run a single three-group analysis using the 
indepsamplesF statistic?

I know I already asked you this question earlier but a bit different, but I'm still 
insecure about this. You answered my previous question with:
alternatively, you may run a single three-group analyis...
But are two single cluster-based analyses also allowed in this case in your 
opinion?

Many thanks in advance,
Best emanuel

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From e.maris at DONDERS.RU.NL  Tue Nov  2 22:32:22 2010
From: e.maris at DONDERS.RU.NL (Eric Maris)
Date: Tue, 2 Nov 2010 22:32:22 +0100
Subject: cluster based analysis
In-Reply-To: <LISTSERV%201011022223222720.1CB0@NIC.SURFNET.NL>
Message-ID: <TUE.2.NOV.2010.223222.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Emanuel,

> Is it allowed to do two single cluster-based analyses with the above
> mentioned pairs and with a Bonferroni correction of the p-value for the
> two
> comparisons or is it required to run a single three-group analysis
> using the
> indepsamplesF statistic?

Two cluster-based analyses plus Bonferroni correction is allowed.

Good luck,

Eric


>
> I know I already asked you this question earlier but a bit different,
> but I'm still
> insecure about this. You answered my previous question with:
> alternatively, you may run a single three-group analyis...
> But are two single cluster-based analyses also allowed in this case in
> your
> opinion?
>
> Many thanks in advance,
> Best emanuel
>
> -----------------------------------------------------------------------
> ----
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> -----------------------------------------------------------------------
> ----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From karl.doron at GMAIL.COM  Wed Nov  3 00:08:51 2010
From: karl.doron at GMAIL.COM (Karl Doron)
Date: Wed, 3 Nov 2010 00:08:51 +0100
Subject: Return index of rejected trials
Message-ID: <WED.3.NOV.2010.000851.0100.FIELDTRIP@NIC.SURFNET.NL>

Hello,

Is it possible to have ft_artifact_eog (or artifact_zvalue) return the index of any 
rejected trials? I'm looking for it in terms of the index of the input data. 

For example, if my trial definition function creates 100 trials and artifact_eog 
(and zvalue) find that trials 8, 15 and 38 should be rejected, can I output a 
vector=[8 15 38]?

cfg.trl and cfg.trlold give the beginning and end of each rejected trial in terms of 
experiment time.

Thanks for any help.

Karl Doron
PhD candidate
UC, Santa Barbara

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From karl.doron at GMAIL.COM  Wed Nov  3 00:29:29 2010
From: karl.doron at GMAIL.COM (Karl Doron)
Date: Wed, 3 Nov 2010 00:29:29 +0100
Subject: Return index of rejected trials
Message-ID: <WED.3.NOV.2010.002929.0100.FIELDTRIP@NIC.SURFNET.NL>

I answered my own question!

new=data.cfg.trl(:,1);
old=data.cfg.trlold(:,1);

[TF, ~]=ismember(old, new);
for i=1:length(TF)
   if TF(i)==0
      rej(i)=i;
  end
end

rejected=nonzeros(rej);

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From maarten.de.vos at UNI-OLDENBURG.DE  Wed Nov  3 10:09:05 2010
From: maarten.de.vos at UNI-OLDENBURG.DE (Maarten De Vos)
Date: Wed, 3 Nov 2010 10:09:05 +0100
Subject: Remove muscle artifacts using ICA
In-Reply-To: <05CCB530-2AD1-42CF-B6B4-9898D5224008@donders.ru.nl>
Message-ID: <WED.3.NOV.2010.100905.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Marc,

sometimes ICA is suboptimal for muscle artifacts.  Not always, depends
indeed how your data look like.

for an alternative method, please see

De Clercq W., Vergult A., Vanrumste B., Van Paesschen W., Van Huffel S.,
"Canonical Correlation Analysis Applied to Remove Muscle Artifacts From
the Electroencephalogram", IEEE Transactions on Biomedical Engineering,
Vol.  53, No. 12, December 2006, pp. 2583-2587.

and De Vos M, Riès S, Vanderperren K, Vanrumste B, Alario FX, Van Huffel
S, Burle B.
Neuroinformatics. 2010 Jun;8(2):135-50.
Removal of muscle artifacts from EEG recordings of spoken language
production.


Hope this helps,
maarten

jan-mathijs schoffelen wrote:
> Dear Marc,
>
> Your figures seem to be missing, so it is hard to judge what the
> artifacts look like exactly. Could it be that one of your head
> localization coils was switched on througout the measurement?
> In general, if your goal is to do source localization, I would not try
> to fix ugly channels, but just omit them from the sensor-array,
> because there will be plenty of sensors left.
> The fixing operation (whatever way it is done, e.g. nearest neighbour
> interpolation, ICA etc) involves replacing each channel's estimate by
> a linear combination of a subset of/all other channels. You have to
> keep in mind that the solution to the forward model (i.e. the
> leadfields for the sources you want to estimate) have to take the same
> linear operation into account in order to give correct results.
> As such, irrespective of the fact that the noisy channels are on the
> edge of the array, interpolation does not really make sense, because
> you are not really improving the quality of your total signal array.
> Also, in this case, I don't expect that rejecting the independent
> component capturing the artifact will be that beneficial, because most
> likely the spatial topography of this component of this component will
> be confined to the three bad guys, with more or less random loadings
> on the rest of the channels. Did you check whether the artifact is
> present at the level of the reference sensors? If that's the case, you
> could consider applying the cfw and afw (compute fixed weights, and
> apply fixed weights) utilities from the 4D software.
>
> Best wishes
>
> Jan-Mathijs
>
>
> On Oct 28, 2010, at 7:11 PM, Marc Recasens wrote:
>
>> Dear all,
>>
>> I have quite a naive question.
>> I'm processing some MEG (4-D) datasets in order to use source
>> location methods afterwards. One of my concerns is that I have some
>> channels (3 in a row) with a steady high frequency artifact >50Hz (I
>> thought it is muscle activity, However it is very tonic and present
>> during the whole recording) which is within my frequencies of
>> interest. This can be seen in the attached figures: timelocked
>> responses bandpass filtered between 15 and 150 Hz, and time-frequency
>> activity between 50 and 100 Hz.
>> As the artefactual channels are put altogether in the right edge of
>> the sensor array (A148, A147 and A146) interpolation may not be a
>> suitable method to eliminate those artefactual channels. (?)
>>
>> I was wondering whether it is possible to correct those artifacts
>> using ICA in such a way similar to ECG artifact removal using
>> component analysis, that is, by identifying  and remove those
>> components in the source analysis that explain the high-frequency
>> artifacts present in some of my channels.
>>
>> Thanks a lot.
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> --
>> Marc Recasens
>> Tel.: +34 639 24 15 98
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the FieldTrip list. The aim of this list is to facilitate the discussion
>> between users of the FieldTrip toolbox, to share experiences
>> and to discuss new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>>
>
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl <mailto:J.Schoffelen at donders.ru.nl>
> Telephone: 0031-24-3614793
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From shackman at WISC.EDU  Wed Nov  3 14:42:08 2010
From: shackman at WISC.EDU (Alexander J. Shackman)
Date: Wed, 3 Nov 2010 08:42:08 -0500
Subject: Remove muscle artifacts using ICA
In-Reply-To: <4CD126B1.9030106@uni-oldenburg.de>
Message-ID: <WED.3.NOV.2010.084208.0500.>

re: ica

you might also take a look at,

http://psyphz.psych.wisc.edu/%7Eshackman/mcmenamin_shackman_davidson_ni2010.pdf

in particular, the supplement appended to the end.

good luck,
alex

On Wed, Nov 3, 2010 at 4:09 AM, Maarten De Vos <
maarten.de.vos at uni-oldenburg.de> wrote:

> Dear Marc,
>
> sometimes ICA is suboptimal for muscle artifacts.  Not always, depends
> indeed how your data look like.
>
> for an alternative method, please see
>
> De Clercq W., Vergult A., Vanrumste B., Van Paesschen W., Van Huffel S.,
> "Canonical Correlation Analysis Applied to Remove Muscle Artifacts From the
> Electroencephalogram", IEEE Transactions on Biomedical Engineering, Vol.
>  53, No. 12, December 2006, pp. 2583-2587.
>
> and De Vos M, Riès S, Vanderperren K, Vanrumste B, Alario FX, Van Huffel S,
> Burle B.
> Neuroinformatics. 2010 Jun;8(2):135-50.
> Removal of muscle artifacts from EEG recordings of spoken language
> production.
>
>
> Hope this helps,
> maarten
>
> jan-mathijs schoffelen wrote:
>
>> Dear Marc,
>>
>> Your figures seem to be missing, so it is hard to judge what the artifacts
>> look like exactly. Could it be that one of your head localization coils was
>> switched on througout the measurement?
>> In general, if your goal is to do source localization, I would not try to
>> fix ugly channels, but just omit them from the sensor-array, because there
>> will be plenty of sensors left.
>> The fixing operation (whatever way it is done, e.g. nearest neighbour
>> interpolation, ICA etc) involves replacing each channel's estimate by a
>> linear combination of a subset of/all other channels. You have to keep in
>> mind that the solution to the forward model (i.e. the leadfields for the
>> sources you want to estimate) have to take the same linear operation into
>> account in order to give correct results. As such, irrespective of the fact
>> that the noisy channels are on the edge of the array, interpolation does not
>> really make sense, because you are not really improving the quality of your
>> total signal array. Also, in this case, I don't expect that rejecting the
>> independent component capturing the artifact will be that beneficial,
>> because most likely the spatial topography of this component of this
>> component will be confined to the three bad guys, with more or less random
>> loadings on the rest of the channels. Did you check whether the artifact is
>> present at the level of the reference sensors? If that's the case, you could
>> consider applying the cfw and afw (compute fixed weights, and apply fixed
>> weights) utilities from the 4D software.
>> Best wishes
>>
>> Jan-Mathijs
>>
>>
>> On Oct 28, 2010, at 7:11 PM, Marc Recasens wrote:
>>
>>  Dear all,
>>>
>>> I have quite a naive question.
>>> I'm processing some MEG (4-D) datasets in order to use source location
>>> methods afterwards. One of my concerns is that I have some channels (3 in a
>>> row) with a steady high frequency artifact >50Hz (I thought it is muscle
>>> activity, However it is very tonic and present during the whole recording)
>>> which is within my frequencies of interest. This can be seen in the attached
>>> figures: timelocked responses bandpass filtered between 15 and 150 Hz, and
>>> time-frequency activity between 50 and 100 Hz.
>>> As the artefactual channels are put altogether in the right edge of the
>>> sensor array (A148, A147 and A146) interpolation may not be a suitable
>>> method to eliminate those artefactual channels. (?)
>>>
>>> I was wondering whether it is possible to correct those artifacts using
>>> ICA in such a way similar to ECG artifact removal using component analysis,
>>> that is, by identifying  and remove those components in the source analysis
>>> that explain the high-frequency artifacts present in some of my channels.
>>>
>>> Thanks a lot.
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> --
>>> Marc Recasens
>>> Tel.: +34 639 24 15 98
>>>
>>> ---------------------------------------------------------------------------
>>> You are receiving this message because you are subscribed to
>>> the FieldTrip list. The aim of this list is to facilitate the discussion
>>> between users of the FieldTrip toolbox, to share experiences
>>> and to discuss new ideas for MEG and EEG analysis.
>>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>>
>>> ---------------------------------------------------------------------------
>>>
>>>
>> Dr. J.M. (Jan-Mathijs) Schoffelen Donders Institute for Brain, Cognition
>> and Behaviour, Centre for Cognitive Neuroimaging,
>> Radboud University Nijmegen, The Netherlands
>> J.Schoffelen at donders.ru.nl <mailto:J.Schoffelen at donders.ru.nl>
>> Telephone: 0031-24-3614793
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the FieldTrip list. The aim of this list is to facilitate the discussion
>> between users of the FieldTrip toolbox, to share experiences
>> and to discuss new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>
>> ---------------------------------------------------------------------------
>>
>>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>



-- 
Alexander J. Shackman, Ph.D.
Wisconsin Psychiatric Institute & Clinics and
Department of Psychology
University of Wisconsin-Madison
1202 West Johnson Street
Madison, Wisconsin 53706

Telephone: +1 (608) 358-5025
Fax: +1 (608) 265-2875
Email: shackman at wisc.edu
http://psyphz.psych.wisc.edu/~shackman

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101103/19ce1d88/attachment.htm>

From shackman at WISC.EDU  Wed Nov  3 17:41:23 2010
From: shackman at WISC.EDU (Alexander J. Shackman)
Date: Wed, 3 Nov 2010 11:41:23 -0500
Subject: Remove muscle artifacts using ICA
In-Reply-To: <AANLkTi=S3q057g=T6Ta+tFhD0T0g0u1VSC4HRgtV7pUC@mail.gmail.com>
Message-ID: <WED.3.NOV.2010.114123.0500.>

and, you might also take a look at makeig's new paper on using ica to remove
artifact from EEG acquired while participants walked on a treadmill,

http://www.frontiersin.org/Human_Neuroscience/10.3389/fnhum.2010.00202/abstract


hth,
alex

On Wed, Nov 3, 2010 at 8:42 AM, Alexander J. Shackman <shackman at wisc.edu>wrote:

> re: ica
>
> you might also take a look at,
>
>
> http://psyphz.psych.wisc.edu/%7Eshackman/mcmenamin_shackman_davidson_ni2010.pdf
>
> in particular, the supplement appended to the end.
>
> good luck,
> alex
>
>
> On Wed, Nov 3, 2010 at 4:09 AM, Maarten De Vos <
> maarten.de.vos at uni-oldenburg.de> wrote:
>
>> Dear Marc,
>>
>> sometimes ICA is suboptimal for muscle artifacts.  Not always, depends
>> indeed how your data look like.
>>
>> for an alternative method, please see
>>
>> De Clercq W., Vergult A., Vanrumste B., Van Paesschen W., Van Huffel S.,
>> "Canonical Correlation Analysis Applied to Remove Muscle Artifacts From the
>> Electroencephalogram", IEEE Transactions on Biomedical Engineering, Vol.
>>  53, No. 12, December 2006, pp. 2583-2587.
>>
>> and De Vos M, Riès S, Vanderperren K, Vanrumste B, Alario FX, Van Huffel
>> S, Burle B.
>> Neuroinformatics. 2010 Jun;8(2):135-50.
>> Removal of muscle artifacts from EEG recordings of spoken language
>> production.
>>
>>
>> Hope this helps,
>> maarten
>>
>> jan-mathijs schoffelen wrote:
>>
>>> Dear Marc,
>>>
>>> Your figures seem to be missing, so it is hard to judge what the
>>> artifacts look like exactly. Could it be that one of your head localization
>>> coils was switched on througout the measurement?
>>> In general, if your goal is to do source localization, I would not try to
>>> fix ugly channels, but just omit them from the sensor-array, because there
>>> will be plenty of sensors left.
>>> The fixing operation (whatever way it is done, e.g. nearest neighbour
>>> interpolation, ICA etc) involves replacing each channel's estimate by a
>>> linear combination of a subset of/all other channels. You have to keep in
>>> mind that the solution to the forward model (i.e. the leadfields for the
>>> sources you want to estimate) have to take the same linear operation into
>>> account in order to give correct results. As such, irrespective of the fact
>>> that the noisy channels are on the edge of the array, interpolation does not
>>> really make sense, because you are not really improving the quality of your
>>> total signal array. Also, in this case, I don't expect that rejecting the
>>> independent component capturing the artifact will be that beneficial,
>>> because most likely the spatial topography of this component of this
>>> component will be confined to the three bad guys, with more or less random
>>> loadings on the rest of the channels. Did you check whether the artifact is
>>> present at the level of the reference sensors? If that's the case, you could
>>> consider applying the cfw and afw (compute fixed weights, and apply fixed
>>> weights) utilities from the 4D software.
>>> Best wishes
>>>
>>> Jan-Mathijs
>>>
>>>
>>> On Oct 28, 2010, at 7:11 PM, Marc Recasens wrote:
>>>
>>>  Dear all,
>>>>
>>>> I have quite a naive question.
>>>> I'm processing some MEG (4-D) datasets in order to use source location
>>>> methods afterwards. One of my concerns is that I have some channels (3 in a
>>>> row) with a steady high frequency artifact >50Hz (I thought it is muscle
>>>> activity, However it is very tonic and present during the whole recording)
>>>> which is within my frequencies of interest. This can be seen in the attached
>>>> figures: timelocked responses bandpass filtered between 15 and 150 Hz, and
>>>> time-frequency activity between 50 and 100 Hz.
>>>> As the artefactual channels are put altogether in the right edge of the
>>>> sensor array (A148, A147 and A146) interpolation may not be a suitable
>>>> method to eliminate those artefactual channels. (?)
>>>>
>>>> I was wondering whether it is possible to correct those artifacts using
>>>> ICA in such a way similar to ECG artifact removal using component analysis,
>>>> that is, by identifying  and remove those components in the source analysis
>>>> that explain the high-frequency artifacts present in some of my channels.
>>>>
>>>> Thanks a lot.
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Marc Recasens
>>>> Tel.: +34 639 24 15 98
>>>>
>>>> ---------------------------------------------------------------------------
>>>> You are receiving this message because you are subscribed to
>>>> the FieldTrip list. The aim of this list is to facilitate the discussion
>>>> between users of the FieldTrip toolbox, to share experiences
>>>> and to discuss new ideas for MEG and EEG analysis.
>>>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>>>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>>>
>>>> ---------------------------------------------------------------------------
>>>>
>>>>
>>> Dr. J.M. (Jan-Mathijs) Schoffelen Donders Institute for Brain, Cognition
>>> and Behaviour, Centre for Cognitive Neuroimaging,
>>> Radboud University Nijmegen, The Netherlands
>>> J.Schoffelen at donders.ru.nl <mailto:J.Schoffelen at donders.ru.nl>
>>> Telephone: 0031-24-3614793
>>>
>>> ---------------------------------------------------------------------------
>>> You are receiving this message because you are subscribed to
>>> the FieldTrip list. The aim of this list is to facilitate the discussion
>>> between users of the FieldTrip toolbox, to share experiences
>>> and to discuss new ideas for MEG and EEG analysis.
>>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>>
>>> ---------------------------------------------------------------------------
>>>
>>>
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>
>> ---------------------------------------------------------------------------
>>
>
>
>
> --
> Alexander J. Shackman, Ph.D.
> Wisconsin Psychiatric Institute & Clinics and
> Department of Psychology
> University of Wisconsin-Madison
> 1202 West Johnson Street
> Madison, Wisconsin 53706
>
> Telephone: +1 (608) 358-5025
> Fax: +1 (608) 265-2875
> Email: shackman at wisc.edu
> http://psyphz.psych.wisc.edu/~shackman<http://psyphz.psych.wisc.edu/%7Eshackman>
>



-- 
Alexander J. Shackman, Ph.D.
Wisconsin Psychiatric Institute & Clinics and
Department of Psychology
University of Wisconsin-Madison
1202 West Johnson Street
Madison, Wisconsin 53706

Telephone: +1 (608) 358-5025
Fax: +1 (608) 265-2875
Email: shackman at wisc.edu
http://psyphz.psych.wisc.edu/~shackman

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101103/32658b27/attachment.htm>

From megjim1 at GMAIL.COM  Thu Nov  4 06:17:08 2010
From: megjim1 at GMAIL.COM (Jim Li)
Date: Thu, 4 Nov 2010 06:17:08 +0100
Subject: what's the planar gradient unit?
Message-ID: <THU.4.NOV.2010.061708.0100.FIELDTRIP@NIC.SURFNET.NL>

Hello,

Can anybody help answer Marcel's question? For example, after 
running "FT_MEGPLANAR" we can get a planar gradient of, say, 4.21e-13, for 
some channel. Is that number in the unit of "T/m" or what?

Thanks a lot.

Jim


On Fri, 4 May 2007 15:38:44 +0200, Marcel Bastiaansen 
<Marcel.Bastiaansen at FCDONDERS.RU.NL> wrote:

>Hi,
>
>can anyone tell me what the unit is for planar gradients? Is that fT /
>square meter, or something else?
>
>Thanks,
>Marcel
>
>--
>dr. Marcel C.M. Bastiaansen.
>
>Max Planck Institute for Psycholinguistics
>Visiting Adress: Wundtlaan 1, 6525 XD Nijmegen, the Netherlands
>Mailing adress: P.O. Box 310, 6500 AH Nijmegen, the Netherlands
>phone: +31 24 3521 347
>fax: 	 +31 24 3521 213
>mail: marcel.bastiaansen at mpi.nl
>web: http://www.mpi.nl/Members/MarcelBastiaansen
>
>and
>
>FC Donders Centre for Cognitive Neuroimaging
>Visiting address: Kapittelweg 29, 6525 EN Nijmegen, the Netherlands
>Mailing address: PO Box 9101, 6500 HB Nijmegen, the Netherlands
>phone: + 31 24 3610 882
>fax:   + 31 24 3610 989
>mail: marcel.bastiaansen at fcdonders.ru.nl
>web: http://www.ru.nl/aspx/get.aspx?
xdl=/views/run/xdl/page&ItmIdt=20592&SitIdt=119&VarIdt=96
>--
>
>----------------------------------
>The aim of this list is to facilitate the discussion between users of the 
FieldTrip  toolbox, to share experiences and to discuss new ideas for MEG and 
EEG analysis.
>  http://listserv.surfnet.nl/archives/fieldtrip.html
>  http://www.ru.nl/fcdonders/fieldtrip/

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From mark.drakesmith at POSTGRAD.MANCHESTER.AC.UK  Thu Nov  4 19:11:10 2010
From: mark.drakesmith at POSTGRAD.MANCHESTER.AC.UK (Mark Drakesmith)
Date: Thu, 4 Nov 2010 18:11:10 +0000
Subject: using reference gradiometers with preproc_denoise
Message-ID: <THU.4.NOV.2010.181110.0000.FIELDTRIP@NIC.SURFNET.NL>

Hi

I am just looking over some MEG data and was wondering what is the best
way of dealing with noise. the 4D MEG scanner includes 11 reference
coils for detecting noise within the MSR. What is the best way of using
this for data-cleaning? I am currently using preproc_denoise to do this,
but the description suggests it should be used when continuous head
motion channels are used, which is not the case here. Is it appropriate
to use preproc_denoise or should I be using an ICA-type approach?

Any help clearing up this confusion would be greatly appreciated.

Regards

Mark

--

Mark Drakesmith
PhD Student

Neuroscience and Aphasia Research Unit (NARU)
University of Manchester

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From daz at MIT.EDU  Thu Nov  4 20:24:55 2010
From: daz at MIT.EDU (David Ziegler)
Date: Thu, 4 Nov 2010 15:24:55 -0400
Subject: ft_freqstatistics between two groups
Message-ID: <THU.4.NOV.2010.152455.0400.FIELDTRIP@NIC.SURFNET.NL>

Hi Fieldtrippers,

I am trying to run a comparison between TFRs from two groups of subjects
and I keep getting some errors that I can't track down answers for.  I
seem to recall something like this being discussed on this list, but I
can't for the life of me track down that thread at the moment.

I am using data from a neuromag 306 system on which I have calculated
TFRs on the gradiometer data, then ran ft_combineplanar, followed by
ft_freqdescriptives, followed by ft_freqgrandaverage for each of the two
groups with the cfg.keepindividual = 'yes' option.  I am able to plot
the grand averages just fine, so the data seem to be ok (and there are
fairly striking differences between the two).

When I run a permutation test to quantify the group differences, I get
the following error messages (although the analysis does run):

/computing statistic 500 from 500
Warning: Not all replications are used for the computation of the statistic.
 > > In statfun_indepsamplesT at 57
   In statistics_montecarlo at 298
   In fieldtrip-20100617/private/statistics_wrapper at 285
   In ft_freqstatistics at 105
Warning: Divide by zero./

When I inspect the output file, the .stat contains a single column of
NaNs.  Does anyone know what I am doing wrong here?

Here is the actual code I am using to run the statistics:

cfg = [];
cfg.channel          = {'MEG *3'}; %only combined gradiometer data
cfg.layout = 'neuromag306cmb_dz.lay';
cfg.latency     = [0.2 0.8];
cfg.avgovertime = 'yes';
cfg.avgoverchan      = 'no';
cfg.avgoverfreq      = 'yes';
cfg.parameter   = 'powspctrm';
cfg.frequency        = [14 26];
cfg.method           = 'montecarlo';
cfg.statistic        = 'indepsamplesT';
cfg.correctm         = 'no';
cfg.clusteralpha     = 0.05;
cfg.clusterstatistic = 'maxsum';
cfg.minnbchan        = 2;
cfg.tail             = 0;
cfg.clustertail      = 0;
cfg.alpha            = 0.05;
cfg.numrandomization = 500;

cfg.design           = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
20 21 22 23 24 25 ;   % subject number
                                     1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2
2 2 2 2 2 2 2]; % 12subjs in grp1, 13subjs in grp2
cfg.uvar = 1;
cfg.ivar = 2;

GA_low_stat = ft_freqstatistics(cfg, GA_grp1_low, GA_grp2_low)

Thanks,
David


--

David A. Ziegler

Department of Brain and Cognitive Sciences
Massachusetts Institute of Technology
43 Vassar St,46-5121
Cambridge, MA 02139

Tel: 617-258-0765

Fax: 617-253-1504

daz at mit.edu <mailto:daz at mit.edu>


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101104/63dde3c4/attachment.htm>

From a.stolk at FCDONDERS.RU.NL  Fri Nov  5 08:39:13 2010
From: a.stolk at FCDONDERS.RU.NL (a.stolk@fcdonders.ru.nl)
Date: Fri, 5 Nov 2010 08:39:13 +0100
Subject: ft_freqstatistics between two groups
In-Reply-To: <5040169.441471288942302823.JavaMail.root@watertor.uci.ru.nl>
Message-ID: <FRI.5.NOV.2010.083913.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi David,

Did you add the comment '%subject number' in your post or in your code? To rule out this is the bottleneck, please try the same again and use this line of code:

cfg.design = [1:25 ; ones(1,12) ones(1,13)*2];

Best,
Arjen




----- Original Message -----
From: "David Ziegler" <daz at MIT.EDU>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Thursday, November 4, 2010 8:24:55 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: [FIELDTRIP] ft_freqstatistics between two groups

Hi Fieldtrippers,

I am trying to run a comparison between TFRs from two groups of subjects
and I keep getting some errors that I can't track down answers for.  I
seem to recall something like this being discussed on this list, but I
can't for the life of me track down that thread at the moment.

I am using data from a neuromag 306 system on which I have calculated
TFRs on the gradiometer data, then ran ft_combineplanar, followed by
ft_freqdescriptives, followed by ft_freqgrandaverage for each of the two
groups with the cfg.keepindividual = 'yes' option.  I am able to plot
the grand averages just fine, so the data seem to be ok (and there are
fairly striking differences between the two).

When I run a permutation test to quantify the group differences, I get
the following error messages (although the analysis does run):

/computing statistic 500 from 500
Warning: Not all replications are used for the computation of the statistic.
 > > In statfun_indepsamplesT at 57
   In statistics_montecarlo at 298
   In fieldtrip-20100617/private/statistics_wrapper at 285
   In ft_freqstatistics at 105
Warning: Divide by zero./

When I inspect the output file, the .stat contains a single column of
NaNs.  Does anyone know what I am doing wrong here?

Here is the actual code I am using to run the statistics:

cfg = [];
cfg.channel          = {'MEG *3'}; %only combined gradiometer data
cfg.layout = 'neuromag306cmb_dz.lay';
cfg.latency     = [0.2 0.8];
cfg.avgovertime = 'yes';
cfg.avgoverchan      = 'no';
cfg.avgoverfreq      = 'yes';
cfg.parameter   = 'powspctrm';
cfg.frequency        = [14 26];
cfg.method           = 'montecarlo';
cfg.statistic        = 'indepsamplesT';
cfg.correctm         = 'no';
cfg.clusteralpha     = 0.05;
cfg.clusterstatistic = 'maxsum';
cfg.minnbchan        = 2;
cfg.tail             = 0;
cfg.clustertail      = 0;
cfg.alpha            = 0.05;
cfg.numrandomization = 500;

cfg.design           = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
20 21 22 23 24 25 ;   % subject number
                                     1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2
2 2 2 2 2 2 2]; % 12subjs in grp1, 13subjs in grp2
cfg.uvar = 1;
cfg.ivar = 2;

GA_low_stat = ft_freqstatistics(cfg, GA_grp1_low, GA_grp2_low)

Thanks,
David


--

David A. Ziegler

Department of Brain and Cognitive Sciences
Massachusetts Institute of Technology
43 Vassar St,46-5121
Cambridge, MA 02139

Tel: 617-258-0765

Fax: 617-253-1504

daz at mit.edu <mailto:daz at mit.edu>


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jan.schoffelen at DONDERS.RU.NL  Fri Nov  5 09:14:37 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Fri, 5 Nov 2010 09:14:37 +0100
Subject: ft_freqstatistics between two groups
In-Reply-To: <4CD30887.9010700@mit.edu>
Message-ID: <FRI.5.NOV.2010.091437.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi David,

It seems you are averaging both over time and frequency in
ft_freqstatistics. As far as I know, the standard mean-function is
used for that. If there are NaNs in your TFR, which happens now and
then at the edges of the TFR, you get a NaN in the average.

Cheers,

Jan-Mathijs


On Nov 4, 2010, at 8:24 PM, David Ziegler wrote:

> Hi Fieldtrippers,
>
> I am trying to run a comparison between TFRs from two groups of
> subjects and I keep getting some errors that I can't track down
> answers for.  I seem to recall something like this being discussed
> on this list, but I can't for the life of me track down that thread
> at the moment.
>
> I am using data from a neuromag 306 system on which I have
> calculated TFRs on the gradiometer data, then ran ft_combineplanar,
> followed by ft_freqdescriptives, followed by ft_freqgrandaverage for
> each of the two groups with the cfg.keepindividual = 'yes' option.
> I am able to plot the grand averages just fine, so the data seem to
> be ok (and there are fairly striking differences between the two).
>
> When I run a permutation test to quantify the group differences, I
> get the following error messages (although the analysis does run):
>
> computing statistic 500 from 500
> Warning: Not all replications are used for the computation of the
> statistic.
> > > In statfun_indepsamplesT at 57
>   In statistics_montecarlo at 298
>   In fieldtrip-20100617/private/statistics_wrapper at 285
>   In ft_freqstatistics at 105
> Warning: Divide by zero.
>
> When I inspect the output file, the .stat contains a single column
> of NaNs.  Does anyone know what I am doing wrong here?
>
> Here is the actual code I am using to run the statistics:
>
> cfg = [];
> cfg.channel          = {'MEG *3'}; %only combined gradiometer data
> cfg.layout = 'neuromag306cmb_dz.lay';
> cfg.latency     = [0.2 0.8];
> cfg.avgovertime = 'yes';
> cfg.avgoverchan      = 'no';
> cfg.avgoverfreq      = 'yes';
> cfg.parameter   = 'powspctrm';
> cfg.frequency        = [14 26];
> cfg.method           = 'montecarlo';
> cfg.statistic        = 'indepsamplesT';
> cfg.correctm         = 'no';
> cfg.clusteralpha     = 0.05;
> cfg.clusterstatistic = 'maxsum';
> cfg.minnbchan        = 2;
> cfg.tail             = 0;
> cfg.clustertail      = 0;
> cfg.alpha            = 0.05;
> cfg.numrandomization = 500;
>
> cfg.design           = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
> 19 20 21 22 23 24 25 ;   % subject number
>                                     1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2
> 2 2 2 2 2 2 2 2 2]; % 12subjs in grp1, 13subjs in grp2
> cfg.uvar = 1;
> cfg.ivar = 2;
>
> GA_low_stat = ft_freqstatistics(cfg, GA_grp1_low, GA_grp2_low)
>
> Thanks,
> David
>
>
> --
> David A. Ziegler
> Department of Brain and Cognitive Sciences
> Massachusetts Institute of Technology
> 43 Vassar St,  46-5121
> Cambridge, MA  02139
> Tel: 617-258-0765
> Fax: 617-253-1504
> daz at mit.edu
>
>
> --------------------------------------------------------------------------- You
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/d878e0f3/attachment.htm>

From jan.schoffelen at DONDERS.RU.NL  Fri Nov  5 09:20:32 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Fri, 5 Nov 2010 09:20:32 +0100
Subject: using reference gradiometers with preproc_denoise
In-Reply-To: <4CD2F73E.5000306@postgrad.manchester.ac.uk>
Message-ID: <FRI.5.NOV.2010.092032.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Mark,

preproc_denoise has been specifically designed to remove the very high
amplitude coil signals generated by the 4D system when continuous head
localization is switched on. It is regressing out the signals on the
reference coils on a trial by trial basis. The signal to noise of this
artifact is huge (in fact, you don't see any brain signal when the
coils are switched on), and as a consequence of this the regression
coefficients are relatively stable across trials. In order to remove
lower amplitude environmental noise, a single trial estimate of the
regression coefficients is probably not what you want. The 4D-software
comes with the command line utitilties cfw and afw, which computes a
set of balancing coefficients given some input data (typically across
a whole dataset). Did you try to use this? I have a matlab
implementation which achieves the same thing, but it is not yet part
of general FieldTrip.

Best,

Jan-Mathijs


On Nov 4, 2010, at 7:11 PM, Mark Drakesmith wrote:

> Hi
>
> I am just looking over some MEG data and was wondering what is the
> best way of dealing with noise. the 4D MEG scanner includes 11
> reference coils for detecting noise within the MSR. What is the best
> way of using this for data-cleaning? I am currently using
> preproc_denoise to do this, but the description suggests it should
> be used when continuous head motion channels are used, which is not
> the case here. Is it appropriate to use preproc_denoise or should I
> be using an ICA-type approach?
>
> Any help clearing up this confusion would be greatly appreciated.
>
> Regards
>
> Mark
>
> --
>
> Mark Drakesmith
> PhD Student
>
> Neuroscience and Aphasia Research Unit (NARU)
> University of Manchester
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jan.schoffelen at DONDERS.RU.NL  Fri Nov  5 09:22:24 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Fri, 5 Nov 2010 09:22:24 +0100
Subject: what's the planar gradient unit?
In-Reply-To: <LISTSERV%201011040617086370.3E70@NIC.SURFNET.NL>
Message-ID: <FRI.5.NOV.2010.092224.0100.FIELDTRIP@NIC.SURFNET.NL>

FieldTrip doesn't explicitly know about the physical units (whether
it's femto nano pico kilo or mega), so it is dependent on the system.

If the magnetic field is defined in T, and the channel position in m,
I'd say the unit after planar transformation is T/m


JM

On Nov 4, 2010, at 6:17 AM, Jim Li wrote:

> Hello,
>
> Can anybody help answer Marcel's question? For example, after
> running "FT_MEGPLANAR" we can get a planar gradient of, say,
> 4.21e-13, for
> some channel. Is that number in the unit of "T/m" or what?
>
> Thanks a lot.
>
> Jim
>
>
> On Fri, 4 May 2007 15:38:44 +0200, Marcel Bastiaansen
> <Marcel.Bastiaansen at FCDONDERS.RU.NL> wrote:
>
>> Hi,
>>
>> can anyone tell me what the unit is for planar gradients? Is that
>> fT /
>> square meter, or something else?
>>
>> Thanks,
>> Marcel
>>
>> --
>> dr. Marcel C.M. Bastiaansen.
>>
>> Max Planck Institute for Psycholinguistics
>> Visiting Adress: Wundtlaan 1, 6525 XD Nijmegen, the Netherlands
>> Mailing adress: P.O. Box 310, 6500 AH Nijmegen, the Netherlands
>> phone: +31 24 3521 347
>> fax: 	 +31 24 3521 213
>> mail: marcel.bastiaansen at mpi.nl
>> web: http://www.mpi.nl/Members/MarcelBastiaansen
>>
>> and
>>
>> FC Donders Centre for Cognitive Neuroimaging
>> Visiting address: Kapittelweg 29, 6525 EN Nijmegen, the Netherlands
>> Mailing address: PO Box 9101, 6500 HB Nijmegen, the Netherlands
>> phone: + 31 24 3610 882
>> fax:   + 31 24 3610 989
>> mail: marcel.bastiaansen at fcdonders.ru.nl
>> web: http://www.ru.nl/aspx/get.aspx?
> xdl=/views/run/xdl/page&ItmIdt=20592&SitIdt=119&VarIdt=96
>> --
>>
>> ----------------------------------
>> The aim of this list is to facilitate the discussion between users
>> of the
> FieldTrip  toolbox, to share experiences and to discuss new ideas
> for MEG and
> EEG analysis.
>> http://listserv.surfnet.nl/archives/fieldtrip.html
>> http://www.ru.nl/fcdonders/fieldtrip/
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From mark.drakesmith at POSTGRAD.MANCHESTER.AC.UK  Fri Nov  5 10:15:07 2010
From: mark.drakesmith at POSTGRAD.MANCHESTER.AC.UK (Mark Drakesmith)
Date: Fri, 5 Nov 2010 09:15:07 +0000
Subject: using reference gradiometers with preproc_denoise
In-Reply-To: <2638807A-3D59-4E2E-9E9F-366032EF63D0@donders.ru.nl>
Message-ID: <FRI.5.NOV.2010.091507.0000.FIELDTRIP@NIC.SURFNET.NL>

Thanks for the clarification. That's very helpful. I was not aware of the cfw and afw commands. Would it be possible to obtain the matlab scripts? Our 4d machine is now out of service so accessing the 4d software may be difficult. 
 
Thanks again

Mark Drakesmith


On 5 Nov 2010, at 08:20, jan-mathijs schoffelen <jan.schoffelen at DONDERS.RU.NL> wrote:

> Dear Mark,
> 
> preproc_denoise has been specifically designed to remove the very high amplitude coil signals generated by the 4D system when continuous head localization is switched on. It is regressing out the signals on the reference coils on a trial by trial basis. The signal to noise of this artifact is huge (in fact, you don't see any brain signal when the coils are switched on), and as a consequence of this the regression coefficients are relatively stable across trials. In order to remove lower amplitude environmental noise, a single trial estimate of the regression coefficients is probably not what you want. The 4D-software comes with the command line utitilties cfw and afw, which computes a set of balancing coefficients given some input data (typically across a whole dataset). Did you try to use this? I have a matlab implementation which achieves the same thing, but it is not yet part of general FieldTrip.
> 
> Best,
> 
> Jan-Mathijs
> 
> 
> On Nov 4, 2010, at 7:11 PM, Mark Drakesmith wrote:
> 
>> Hi
>> 
>> I am just looking over some MEG data and was wondering what is the best way of dealing with noise. the 4D MEG scanner includes 11 reference coils for detecting noise within the MSR. What is the best way of using this for data-cleaning? I am currently using preproc_denoise to do this, but the description suggests it should be used when continuous head motion channels are used, which is not the case here. Is it appropriate to use preproc_denoise or should I be using an ICA-type approach?
>> 
>> Any help clearing up this confusion would be greatly appreciated.
>> 
>> Regards
>> 
>> Mark
>> 
>> -- 
>> 
>> Mark Drakesmith
>> PhD Student
>> 
>> Neuroscience and Aphasia Research Unit (NARU)
>> University of Manchester
>> 
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>> 
> 
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl
> Telephone: 0031-24-3614793
> 
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jan.schoffelen at DONDERS.RU.NL  Fri Nov  5 11:07:32 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Fri, 5 Nov 2010 11:07:32 +0100
Subject: using reference gradiometers with preproc_denoise
In-Reply-To: <FFDBAA8B-A304-447D-9842-DAFF6E7D1506@postgrad.manchester.ac.uk>
Message-ID: <FRI.5.NOV.2010.110732.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Mark,

Adding this functionality to the fieldtrip release is on my to do
list. I'll let you know when it's there.

Best,

JM

On Nov 5, 2010, at 10:15 AM, Mark Drakesmith wrote:

> Thanks for the clarification. That's very helpful. I was not aware
> of the cfw and afw commands. Would it be possible to obtain the
> matlab scripts? Our 4d machine is now out of service so accessing
> the 4d software may be difficult.
>
> Thanks again
>
> Mark Drakesmith
>
>
> On 5 Nov 2010, at 08:20, jan-mathijs schoffelen <jan.schoffelen at DONDERS.RU.NL
> > wrote:
>
>> Dear Mark,
>>
>> preproc_denoise has been specifically designed to remove the very
>> high amplitude coil signals generated by the 4D system when
>> continuous head localization is switched on. It is regressing out
>> the signals on the reference coils on a trial by trial basis. The
>> signal to noise of this artifact is huge (in fact, you don't see
>> any brain signal when the coils are switched on), and as a
>> consequence of this the regression coefficients are relatively
>> stable across trials. In order to remove lower amplitude
>> environmental noise, a single trial estimate of the regression
>> coefficients is probably not what you want. The 4D-software comes
>> with the command line utitilties cfw and afw, which computes a set
>> of balancing coefficients given some input data (typically across a
>> whole dataset). Did you try to use this? I have a matlab
>> implementation which achieves the same thing, but it is not yet
>> part of general FieldTrip.
>>
>> Best,
>>
>> Jan-Mathijs
>>
>>
>> On Nov 4, 2010, at 7:11 PM, Mark Drakesmith wrote:
>>
>>> Hi
>>>
>>> I am just looking over some MEG data and was wondering what is the
>>> best way of dealing with noise. the 4D MEG scanner includes 11
>>> reference coils for detecting noise within the MSR. What is the
>>> best way of using this for data-cleaning? I am currently using
>>> preproc_denoise to do this, but the description suggests it should
>>> be used when continuous head motion channels are used, which is
>>> not the case here. Is it appropriate to use preproc_denoise or
>>> should I be using an ICA-type approach?
>>>
>>> Any help clearing up this confusion would be greatly appreciated.
>>>
>>> Regards
>>>
>>> Mark
>>>
>>> --
>>>
>>> Mark Drakesmith
>>> PhD Student
>>>
>>> Neuroscience and Aphasia Research Unit (NARU)
>>> University of Manchester
>>>
>>> ---------------------------------------------------------------------------
>>> You are receiving this message because you are subscribed to
>>> the  FieldTrip list. The aim of this list is to facilitate the
>>> discussion
>>> between  users of the FieldTrip  toolbox, to share experiences
>>> and to discuss  new ideas for MEG and EEG analysis.
>>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>> ---------------------------------------------------------------------------
>>>
>>
>> Dr. J.M. (Jan-Mathijs) Schoffelen
>> Donders Institute for Brain, Cognition and Behaviour,
>> Centre for Cognitive Neuroimaging,
>> Radboud University Nijmegen, The Netherlands
>> J.Schoffelen at donders.ru.nl
>> Telephone: 0031-24-3614793
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From megjim1 at GMAIL.COM  Fri Nov  5 15:18:26 2010
From: megjim1 at GMAIL.COM (Jim Li)
Date: Fri, 5 Nov 2010 15:18:26 +0100
Subject: what's the planar gradient unit?
Message-ID: <FRI.5.NOV.2010.151826.0100.FIELDTRIP@NIC.SURFNET.NL>

That's good to know. Thanks a lot, jan-mathijs, :)

Jim


On Fri, 5 Nov 2010 09:22:24 +0100, jan-mathijs schoffelen 
<jan.schoffelen at DONDERS.RU.NL> wrote:

>FieldTrip doesn't explicitly know about the physical units (whether
>it's femto nano pico kilo or mega), so it is dependent on the system.
>
>If the magnetic field is defined in T, and the channel position in m,
>I'd say the unit after planar transformation is T/m
>
>
>JM
>
>On Nov 4, 2010, at 6:17 AM, Jim Li wrote:
>
>> Hello,
>>
>> Can anybody help answer Marcel's question? For example, after
>> running "FT_MEGPLANAR" we can get a planar gradient of, say,
>> 4.21e-13, for
>> some channel. Is that number in the unit of "T/m" or what?
>>
>> Thanks a lot.
>>
>> Jim
>>
>>
>> On Fri, 4 May 2007 15:38:44 +0200, Marcel Bastiaansen
>> <Marcel.Bastiaansen at FCDONDERS.RU.NL> wrote:
>>
>>> Hi,
>>>
>>> can anyone tell me what the unit is for planar gradients? Is that
>>> fT /
>>> square meter, or something else?
>>>
>>> Thanks,
>>> Marcel
>>>
>>> --
>>> dr. Marcel C.M. Bastiaansen.
>>>
>>> Max Planck Institute for Psycholinguistics
>>> Visiting Adress: Wundtlaan 1, 6525 XD Nijmegen, the Netherlands
>>> Mailing adress: P.O. Box 310, 6500 AH Nijmegen, the Netherlands
>>> phone: +31 24 3521 347
>>> fax: 	 +31 24 3521 213
>>> mail: marcel.bastiaansen at mpi.nl
>>> web: http://www.mpi.nl/Members/MarcelBastiaansen
>>>
>>> and
>>>
>>> FC Donders Centre for Cognitive Neuroimaging
>>> Visiting address: Kapittelweg 29, 6525 EN Nijmegen, the Netherlands
>>> Mailing address: PO Box 9101, 6500 HB Nijmegen, the Netherlands
>>> phone: + 31 24 3610 882
>>> fax:   + 31 24 3610 989
>>> mail: marcel.bastiaansen at fcdonders.ru.nl
>>> web: http://www.ru.nl/aspx/get.aspx?
>> xdl=/views/run/xdl/page&ItmIdt=20592&SitIdt=119&VarIdt=96
>>> --
>>>
>>> ----------------------------------
>>> The aim of this list is to facilitate the discussion between users
>>> of the
>> FieldTrip  toolbox, to share experiences and to discuss new ideas
>> for MEG and
>> EEG analysis.
>>> http://listserv.surfnet.nl/archives/fieldtrip.html
>>> http://www.ru.nl/fcdonders/fieldtrip/
>>
>> ------------------------------------------------------------------------
---
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ------------------------------------------------------------------------
---
>>
>
>Dr. J.M. (Jan-Mathijs) Schoffelen
>Donders Institute for Brain, Cognition and Behaviour,
>Centre for Cognitive Neuroimaging,
>Radboud University Nijmegen, The Netherlands
>J.Schoffelen at donders.ru.nl
>Telephone: 0031-24-3614793
>
>--------------------------------------------------------------------------
-
>You are receiving this message because you are subscribed to
>the  FieldTrip list. The aim of this list is to facilitate the discussion
>between  users of the FieldTrip  toolbox, to share experiences
>and to discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>--------------------------------------------------------------------------
-

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From Antony.Passaro at UTH.TMC.EDU  Fri Nov  5 16:47:32 2010
From: Antony.Passaro at UTH.TMC.EDU (Passaro, Antony D)
Date: Fri, 5 Nov 2010 10:47:32 -0500
Subject: specifying individual lateralization in sourcestatistic
In-Reply-To: <551388379.1832555.1287151689447.JavaMail.fmail@mwmweb053>
Message-ID: <FRI.5.NOV.2010.104732.0500.FIELDTRIP@NIC.SURFNET.NL>

Hi Michael (or anyone else),

I had a question in regards to your comment in this email, specifically where you mention obtaining t-values from first level statistics. In the example on the Fieldtrip website, ft_sourcestatistics describes a method of obtaining the t-values when comparing conditions directly but I was wondering how it might be possible to obtain the t-values by using source statistics for a task-vs-basline comparison for one condition? More specifically, what would have to be changed in the example from the website (posted below)?

cfg = [];
cfg.dim         = source.dim;
cfg.method      = 'montecarlo';
cfg.statistic   = 'indepsamplesT';
cfg.parameter   = 'pow';
cfg.correctm    = 'cluster';
cfg.numrandomization = 1000;
cfg.alpha       = 0.05;
cfg.tail        = 0;
cfg.design(1,:) = [1:length(find(design==1)) 1:length(find(design==2))];
cfg.design(2,:) = design;
cfg.uvar        = 1; % row of design matrix that contains unit variable (in this case: trials)
cfg.ivar        = 2; % row of design matrix that contains independent variable (the conditions)

stat = ft_sourcestatistics(cfg, source);


Thank you very much for your help,
-Tony



-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Michael Wibral
Sent: Friday, October 15, 2010 9:08 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Thomas,

I suggest you simply extract the power values from the results of sourceanalysis (or t-values if you already did a fisrt level statistics) and average them by hand in MATLAB - as ROI is known for each subject this should be easy (you have to extract the values by the voxel indices contained in your ROI. These in turn you can find in interactive mode source plotting if everything else fails). This way you end up with a single value per subject and condition. Afterwards you do a simple permutation test by hand in MATLAB. 

((The test for two conditions for example can be done this way:
1. concatenate all data in a vector D first data in one condition, then in the other) 2. compute your test metric between first and second half of D.
3. shuffle the entries of D: DS=D(randperm(length(D)); % creates a new D with shuffled entries by shuffling the indexes of the old one 4. compute your test metric for DS and remember it 5. Do 3+4 N times (e.g. >1901 times for accurate testing at alpha<0.05) 6. check where your original test metric obtained from D is in the distribution of the mtrices obtained from the DS.))


Hope this helps,
Michael

-----Ursprüngliche Nachricht-----
Von: "Thomas Hartmann" <thomas.hartmann at UNI-KONSTANZ.DE>
Gesendet: Oct 15, 2010 3:30:40 PM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: [FIELDTRIP] specifying individual lateralization in sourcestatistic

>  hi,
>i want to do a roi analysis on source data and average over the all the 
>voxels. the problem is that i am dealing with a lateralized effect that 
>i expect to show up either on the left or the right side of the same 
>structure. this lateralization is individual for each subject and known 
>a priori.
>is there any possibility to individually define, which side to take 
>into account for the statistics?
>
>thanks in advance,
>thomas
>
>--
>Dipl. Psych. Thomas Hartmann
>
>OBOB-Lab
>University of Konstanz
>Department of Psychology
>P.O. Box D25
>78457 Konstanz
>Germany
>
>Tel.: +49 (0)7531 88 4612
>Fax: +49 (0)7531-88 4601
>Email: thomas.hartmann at uni-konstanz.de
>Homepage: http://www.uni-konstanz.de/obob
>
>"I am a brain, Watson. The rest of me is a mere appendix. " (Arthur 
>Conan Doyle)
>
>-----------------------------------------------------------------------
>---- You are receiving this message because you are subscribed to the  
>FieldTrip list. The aim of this list is to facilitate the discussion 
>between  users of the FieldTrip  toolbox, to share experiences and to 
>discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>-----------------------------------------------------------------------
>----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to the  FieldTrip list. The aim of this list is to facilitate the discussion between  users of the FieldTrip  toolbox, to share experiences and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

From a.stolk at FCDONDERS.RU.NL  Fri Nov  5 17:12:17 2010
From: a.stolk at FCDONDERS.RU.NL (a.stolk@fcdonders.ru.nl)
Date: Fri, 5 Nov 2010 17:12:17 +0100
Subject: specifying individual lateralization in sourcestatistic
In-Reply-To: <10744934.455691288973075576.JavaMail.root@watertor.uci.ru.nl>
Message-ID: <FRI.5.NOV.2010.171217.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi Tony,

Basically, you'd only need to change these lines. 

cfg.design = [(ones(1,Ntrials) ones(1,Ntrials)*2];
cfg.ivar = 1; 

stat =  ft_sourcestatistics(cfg, source_task, source_baseline);

Note that you want the SNR of your baseline segments and the task segments to be the same. You'll have to make sure you'll have as many baseline cross-spectral-density matrices (output from your fourieranalysis) as task CSD matrices.

Best regards,
Arjen


----- Original Message -----
From: "Antony D Passaro" <Antony.Passaro at UTH.TMC.EDU>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Friday, November 5, 2010 4:47:32 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Michael (or anyone else),

I had a question in regards to your comment in this email, specifically where you mention obtaining t-values from first level statistics. In the example on the Fieldtrip website, ft_sourcestatistics describes a method of obtaining the t-values when comparing conditions directly but I was wondering how it might be possible to obtain the t-values by using source statistics for a task-vs-basline comparison for one condition? More specifically, what would have to be changed in the example from the website (posted below)?

cfg = [];
cfg.dim         = source.dim;
cfg.method      = 'montecarlo';
cfg.statistic   = 'indepsamplesT';
cfg.parameter   = 'pow';
cfg.correctm    = 'cluster';
cfg.numrandomization = 1000;
cfg.alpha       = 0.05;
cfg.tail        = 0;
cfg.design(1,:) = [1:length(find(design==1)) 1:length(find(design==2))];
cfg.design(2,:) = design;
cfg.uvar        = 1; % row of design matrix that contains unit variable (in this case: trials)
cfg.ivar        = 2; % row of design matrix that contains independent variable (the conditions)

stat = ft_sourcestatistics(cfg, source);


Thank you very much for your help,
-Tony



-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Michael Wibral
Sent: Friday, October 15, 2010 9:08 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Thomas,

I suggest you simply extract the power values from the results of sourceanalysis (or t-values if you already did a fisrt level statistics) and average them by hand in MATLAB - as ROI is known for each subject this should be easy (you have to extract the values by the voxel indices contained in your ROI. These in turn you can find in interactive mode source plotting if everything else fails). This way you end up with a single value per subject and condition. Afterwards you do a simple permutation test by hand in MATLAB. 

((The test for two conditions for example can be done this way:
1. concatenate all data in a vector D first data in one condition, then in the other) 2. compute your test metric between first and second half of D.
3. shuffle the entries of D: DS=D(randperm(length(D)); % creates a new D with shuffled entries by shuffling the indexes of the old one 4. compute your test metric for DS and remember it 5. Do 3+4 N times (e.g. >1901 times for accurate testing at alpha<0.05) 6. check where your original test metric obtained from D is in the distribution of the mtrices obtained from the DS.))


Hope this helps,
Michael

-----Ursprüngliche Nachricht-----
Von: "Thomas Hartmann" <thomas.hartmann at UNI-KONSTANZ.DE>
Gesendet: Oct 15, 2010 3:30:40 PM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: [FIELDTRIP] specifying individual lateralization in sourcestatistic

>  hi,
>i want to do a roi analysis on source data and average over the all the 
>voxels. the problem is that i am dealing with a lateralized effect that 
>i expect to show up either on the left or the right side of the same 
>structure. this lateralization is individual for each subject and known 
>a priori.
>is there any possibility to individually define, which side to take 
>into account for the statistics?
>
>thanks in advance,
>thomas
>
>--
>Dipl. Psych. Thomas Hartmann
>
>OBOB-Lab
>University of Konstanz
>Department of Psychology
>P.O. Box D25
>78457 Konstanz
>Germany
>
>Tel.: +49 (0)7531 88 4612
>Fax: +49 (0)7531-88 4601
>Email: thomas.hartmann at uni-konstanz.de
>Homepage: http://www.uni-konstanz.de/obob
>
>"I am a brain, Watson. The rest of me is a mere appendix. " (Arthur 
>Conan Doyle)
>
>-----------------------------------------------------------------------
>---- You are receiving this message because you are subscribed to the  
>FieldTrip list. The aim of this list is to facilitate the discussion 
>between  users of the FieldTrip  toolbox, to share experiences and to 
>discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>-----------------------------------------------------------------------
>----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to the  FieldTrip list. The aim of this list is to facilitate the discussion between  users of the FieldTrip  toolbox, to share experiences and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From Antony.Passaro at UTH.TMC.EDU  Fri Nov  5 17:30:10 2010
From: Antony.Passaro at UTH.TMC.EDU (Passaro, Antony D)
Date: Fri, 5 Nov 2010 11:30:10 -0500
Subject: specifying individual lateralization in sourcestatistic
In-Reply-To: <12066090.455991288973537890.JavaMail.root@watertor.uci.ru.nl>
Message-ID: <FRI.5.NOV.2010.113010.0500.FIELDTRIP@NIC.SURFNET.NL>

Hi Arjen,

Thank you very much for your reply, that was very helpful. I was wondering would source_task and source_baseline come straight from ft_sourceanalysis or would I first redefine avg.pow in terms of task - baseline / baseline (as in the sourceanalysis example on the Fieldtrip website)?

Thank you,
-Tony 

-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of a.stolk at fcdonders.ru.nl
Sent: Friday, November 05, 2010 11:12 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Tony,

Basically, you'd only need to change these lines. 

cfg.design = [(ones(1,Ntrials) ones(1,Ntrials)*2];
cfg.ivar = 1; 

stat =  ft_sourcestatistics(cfg, source_task, source_baseline);

Note that you want the SNR of your baseline segments and the task segments to be the same. You'll have to make sure you'll have as many baseline cross-spectral-density matrices (output from your fourieranalysis) as task CSD matrices.

Best regards,
Arjen


----- Original Message -----
From: "Antony D Passaro" <Antony.Passaro at UTH.TMC.EDU>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Friday, November 5, 2010 4:47:32 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Michael (or anyone else),

I had a question in regards to your comment in this email, specifically where you mention obtaining t-values from first level statistics. In the example on the Fieldtrip website, ft_sourcestatistics describes a method of obtaining the t-values when comparing conditions directly but I was wondering how it might be possible to obtain the t-values by using source statistics for a task-vs-basline comparison for one condition? More specifically, what would have to be changed in the example from the website (posted below)?

cfg = [];
cfg.dim         = source.dim;
cfg.method      = 'montecarlo';
cfg.statistic   = 'indepsamplesT';
cfg.parameter   = 'pow';
cfg.correctm    = 'cluster';
cfg.numrandomization = 1000;
cfg.alpha       = 0.05;
cfg.tail        = 0;
cfg.design(1,:) = [1:length(find(design==1)) 1:length(find(design==2))];
cfg.design(2,:) = design;
cfg.uvar        = 1; % row of design matrix that contains unit variable (in this case: trials)
cfg.ivar        = 2; % row of design matrix that contains independent variable (the conditions)

stat = ft_sourcestatistics(cfg, source);


Thank you very much for your help,
-Tony



-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Michael Wibral
Sent: Friday, October 15, 2010 9:08 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Thomas,

I suggest you simply extract the power values from the results of sourceanalysis (or t-values if you already did a fisrt level statistics) and average them by hand in MATLAB - as ROI is known for each subject this should be easy (you have to extract the values by the voxel indices contained in your ROI. These in turn you can find in interactive mode source plotting if everything else fails). This way you end up with a single value per subject and condition. Afterwards you do a simple permutation test by hand in MATLAB. 

((The test for two conditions for example can be done this way:
1. concatenate all data in a vector D first data in one condition, then in the other) 2. compute your test metric between first and second half of D.
3. shuffle the entries of D: DS=D(randperm(length(D)); % creates a new D with shuffled entries by shuffling the indexes of the old one 4. compute your test metric for DS and remember it 5. Do 3+4 N times (e.g. >1901 times for accurate testing at alpha<0.05) 6. check where your original test metric obtained from D is in the distribution of the mtrices obtained from the DS.))


Hope this helps,
Michael

-----Ursprüngliche Nachricht-----
Von: "Thomas Hartmann" <thomas.hartmann at UNI-KONSTANZ.DE>
Gesendet: Oct 15, 2010 3:30:40 PM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: [FIELDTRIP] specifying individual lateralization in sourcestatistic

>  hi,
>i want to do a roi analysis on source data and average over the all the 
>voxels. the problem is that i am dealing with a lateralized effect that 
>i expect to show up either on the left or the right side of the same 
>structure. this lateralization is individual for each subject and known 
>a priori.
>is there any possibility to individually define, which side to take 
>into account for the statistics?
>
>thanks in advance,
>thomas
>
>--
>Dipl. Psych. Thomas Hartmann
>
>OBOB-Lab
>University of Konstanz
>Department of Psychology
>P.O. Box D25
>78457 Konstanz
>Germany
>
>Tel.: +49 (0)7531 88 4612
>Fax: +49 (0)7531-88 4601
>Email: thomas.hartmann at uni-konstanz.de
>Homepage: http://www.uni-konstanz.de/obob
>
>"I am a brain, Watson. The rest of me is a mere appendix. " (Arthur 
>Conan Doyle)
>
>-----------------------------------------------------------------------
>---- You are receiving this message because you are subscribed to the  
>FieldTrip list. The aim of this list is to facilitate the discussion 
>between  users of the FieldTrip  toolbox, to share experiences and to 
>discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>-----------------------------------------------------------------------
>----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to the  FieldTrip list. The aim of this list is to facilitate the discussion between  users of the FieldTrip  toolbox, to share experiences and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

From a.stolk at FCDONDERS.RU.NL  Fri Nov  5 17:48:17 2010
From: a.stolk at FCDONDERS.RU.NL (a.stolk@fcdonders.ru.nl)
Date: Fri, 5 Nov 2010 17:48:17 +0100
Subject: specifying individual lateralization in sourcestatistic
In-Reply-To: <9900065.456561288974816996.JavaMail.root@watertor.uci.ru.nl>
Message-ID: <FRI.5.NOV.2010.174817.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi Tony,

Appreciated. The answer to your question depends on what your data looks like and the conclusions you'd like to draw.

1) A baseline-correction might come in handy if you have more task trials than baseline trials. What happens, is that for every every task trial the relative difference is taken against the average of the baselines. At the second level of your analysis, only the average per subject of the relative differences is taken.

Here, the procedure is:
-frequency analysis
-baseline correction
-source analysis 
-sourcegrandaverage
-sourcestatistics

2) When you do T-statistics on tasks vs baselines, the standard deviation plays a role in the computation of your T values which then is a more robust estimate of the difference at the subject level. Preferably you use common filters when doing sourceanalysis as the average spatial filter then is based on more trials (greater SNR). Have a look at our page;   

http://fieldtrip.fcdonders.nl/example/common_filters_in_beamforming

Here, the procedure is:
-source analysis (common filter)
-split the source data into task and baseline
-sourcestatistics 
-sourcegrandaverage
-sourcestatistics


Best regards,
Arjen



----- Original Message -----
From: "Antony D Passaro" <Antony.Passaro at UTH.TMC.EDU>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Friday, November 5, 2010 5:30:10 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Arjen,

Thank you very much for your reply, that was very helpful. I was wondering would source_task and source_baseline come straight from ft_sourceanalysis or would I first redefine avg.pow in terms of task - baseline / baseline (as in the sourceanalysis example on the Fieldtrip website)?

Thank you,
-Tony 

-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of a.stolk at fcdonders.ru.nl
Sent: Friday, November 05, 2010 11:12 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Tony,

Basically, you'd only need to change these lines. 

cfg.design = [(ones(1,Ntrials) ones(1,Ntrials)*2];
cfg.ivar = 1; 

stat =  ft_sourcestatistics(cfg, source_task, source_baseline);

Note that you want the SNR of your baseline segments and the task segments to be the same. You'll have to make sure you'll have as many baseline cross-spectral-density matrices (output from your fourieranalysis) as task CSD matrices.

Best regards,
Arjen


----- Original Message -----
From: "Antony D Passaro" <Antony.Passaro at UTH.TMC.EDU>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Friday, November 5, 2010 4:47:32 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Michael (or anyone else),

I had a question in regards to your comment in this email, specifically where you mention obtaining t-values from first level statistics. In the example on the Fieldtrip website, ft_sourcestatistics describes a method of obtaining the t-values when comparing conditions directly but I was wondering how it might be possible to obtain the t-values by using source statistics for a task-vs-basline comparison for one condition? More specifically, what would have to be changed in the example from the website (posted below)?

cfg = [];
cfg.dim         = source.dim;
cfg.method      = 'montecarlo';
cfg.statistic   = 'indepsamplesT';
cfg.parameter   = 'pow';
cfg.correctm    = 'cluster';
cfg.numrandomization = 1000;
cfg.alpha       = 0.05;
cfg.tail        = 0;
cfg.design(1,:) = [1:length(find(design==1)) 1:length(find(design==2))];
cfg.design(2,:) = design;
cfg.uvar        = 1; % row of design matrix that contains unit variable (in this case: trials)
cfg.ivar        = 2; % row of design matrix that contains independent variable (the conditions)

stat = ft_sourcestatistics(cfg, source);


Thank you very much for your help,
-Tony



-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Michael Wibral
Sent: Friday, October 15, 2010 9:08 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Thomas,

I suggest you simply extract the power values from the results of sourceanalysis (or t-values if you already did a fisrt level statistics) and average them by hand in MATLAB - as ROI is known for each subject this should be easy (you have to extract the values by the voxel indices contained in your ROI. These in turn you can find in interactive mode source plotting if everything else fails). This way you end up with a single value per subject and condition. Afterwards you do a simple permutation test by hand in MATLAB. 

((The test for two conditions for example can be done this way:
1. concatenate all data in a vector D first data in one condition, then in the other) 2. compute your test metric between first and second half of D.
3. shuffle the entries of D: DS=D(randperm(length(D)); % creates a new D with shuffled entries by shuffling the indexes of the old one 4. compute your test metric for DS and remember it 5. Do 3+4 N times (e.g. >1901 times for accurate testing at alpha<0.05) 6. check where your original test metric obtained from D is in the distribution of the mtrices obtained from the DS.))


Hope this helps,
Michael

-----Ursprüngliche Nachricht-----
Von: "Thomas Hartmann" <thomas.hartmann at UNI-KONSTANZ.DE>
Gesendet: Oct 15, 2010 3:30:40 PM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: [FIELDTRIP] specifying individual lateralization in sourcestatistic

>  hi,
>i want to do a roi analysis on source data and average over the all the 
>voxels. the problem is that i am dealing with a lateralized effect that 
>i expect to show up either on the left or the right side of the same 
>structure. this lateralization is individual for each subject and known 
>a priori.
>is there any possibility to individually define, which side to take 
>into account for the statistics?
>
>thanks in advance,
>thomas
>
>--
>Dipl. Psych. Thomas Hartmann
>
>OBOB-Lab
>University of Konstanz
>Department of Psychology
>P.O. Box D25
>78457 Konstanz
>Germany
>
>Tel.: +49 (0)7531 88 4612
>Fax: +49 (0)7531-88 4601
>Email: thomas.hartmann at uni-konstanz.de
>Homepage: http://www.uni-konstanz.de/obob
>
>"I am a brain, Watson. The rest of me is a mere appendix. " (Arthur 
>Conan Doyle)
>
>-----------------------------------------------------------------------
>---- You are receiving this message because you are subscribed to the  
>FieldTrip list. The aim of this list is to facilitate the discussion 
>between  users of the FieldTrip  toolbox, to share experiences and to 
>discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>-----------------------------------------------------------------------
>----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to the  FieldTrip list. The aim of this list is to facilitate the discussion between  users of the FieldTrip  toolbox, to share experiences and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From l.frei at PSY.GLA.AC.UK  Fri Nov  5 18:29:16 2010
From: l.frei at PSY.GLA.AC.UK (Luisa Frei)
Date: Fri, 5 Nov 2010 17:29:16 +0000
Subject: ft_appenddata and denoise_pca causing problems
Message-ID: <FRI.5.NOV.2010.172916.0000.FIELDTRIP@NIC.SURFNET.NL>

>
> Hi,
> I'm sorry if this has been discussed before and if it has, could
> you please direct me to the relevant emails? Thanks.
>
> I am encountering a problem when using ft_appenddata and
> denoise_pca. My MEG experiment  (4D) consists of 10 blocks per
> session, for each of which I have a separate data set.
>
> During preprocessing (after artifact rejection), I concatenate
> these data sets to find denoising weights per session using the
> function denoise_pca for 4D (I do this on shorter 400 ms epochs to
> save computational power). Afterwards, I apply these weights per
> block, downsample the data and concatenate the resulting data again
> in order to do an ICA per session to remove heart beat artifacts. I
> downsample because I use longer epochs to do that (1.5 sec).
>
> However, when I do an ICA on the denoised and concatenated session,
> I get lots of high variance noise components (first figure):
>

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 12.png
Type: application/applefile
Size: 74 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 12.png
Type: image/png
Size: 181659 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment.png>
-------------- next part --------------
>
> Trying to find the root of this, I went back and did this analysis
> for one block only (denoising for one block, no concatenating) and
> the result looks much better (second figure):

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 10.png
Type: application/applefile
Size: 74 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 10.png
Type: image/png
Size: 171390 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment-0001.png>
-------------- next part --------------
>
>
> Then, as a test, I tried to concatenate two blocks, find the
> weights for those two concatenated blocks, apply them to the
> individual blocks, concatenate again and do the ICA on these two
> blocks and I get this (last figure):

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 11.png
Type: application/applefile
Size: 74 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment-0002.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 11.png
Type: image/png
Size: 167953 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment-0002.png>
-------------- next part --------------
>
>
> So, it seems like when denoising per session (the concatenated
> blocks), I introduce noise when I apply the pca weights to the
> individual blocks. Whereas the whole point of the exercise was to
> reduce noise by denoising per session rather than block.
>
> Why is this? Am I doing something fundamentally wrong? I'm
> wondering because a colleague of mine has done an almost identical
> analysis step a while ago and she doesn't get problems with high
> variance noise components. I'm not sure whether the problem lies
> with append_data or denoise-pca, but I know that append_data has
> been changed recently, so this might be one possible source of the
> problem.
>
> I'm relatively new to MEG analysis, so I would be grateful for any
> pointers.
>
> Thanks,
> Luisa
>
> PS: I know that the different head positions between blocks can
> introduce noise, but when comparing the error introduced by head
> movements and the error introduced by correcting for head
> movements, the error was comparable, so correcting the head
> positions doesn't seem worth the effort.
>
>
>
>
>
>


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

From jan.schoffelen at DONDERS.RU.NL  Mon Nov  8 09:07:37 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Mon, 8 Nov 2010 09:07:37 +0100
Subject: ft_appenddata and denoise_pca causing problems
In-Reply-To: <01F75A80-9F52-4956-85B4-CEE86BE9AE71@psy.gla.ac.uk>
Message-ID: <MON.8.NOV.2010.090737.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Luisa,

>
> Hi,
> I'm sorry if this has been discussed before and if it has, could you
> please direct me to the relevant emails? Thanks.
>
Don't worry. This has not yet been discussed here before, and it's an
interesting issue. Yet, probably most people wouldn't know what you
are talking about, because the function denoise_pca is not yet part of
the FieldTrip release version ;o). At the moment, it's only the CCNi
and the fcdc who have it available.

> I am encountering a problem when using ft_appenddata and
> denoise_pca. My MEG experiment  (4D) consists of 10 blocks per
> session, for each of which I have a separate data set.
>
> During preprocessing (after artifact rejection), I concatenate these
> data sets to find denoising weights per session using the function
> denoise_pca for 4D (I do this on shorter 400 ms epochs to save
> computational power). Afterwards, I apply these weights per block,
> downsample the data and concatenate the resulting data again in
> order to do an ICA per session to remove heart beat artifacts. I
> downsample because I use longer epochs to do that (1.5 sec).
> However, when I do an ICA on the denoised and concatenated session,
> I get lots of high variance noise components (first figure):
> Trying to find the root of this, I went back and did this analysis
> for one block only (denoising for one block, no concatenating) and
> the result looks much better (second figure):
> Then, as a test, I tried to concatenate two blocks, find the weights
> for those two concatenated blocks, apply them to the individual
> blocks, concatenate again and do the ICA on these two blocks and I
> get this (last figure):
> So, it seems like when denoising per session (the concatenated
> blocks), I introduce noise when I apply the pca weights to the
> individual blocks. Whereas the whole point of the exercise was to
> reduce noise by denoising per session rather than block.

Denoise_pca indeed tries to reduce the noise in the magnetometer data
by computing a set of balancing coefficients, which are used to
subtract a weighted combination of the signals measured at the
reference sensors from the signals measured at the magnetometer coils.
As such, it is assumed that the signals picked up by the references
reflect purely environmental noise. If there is sensor specific noise,
e.g. a jump in one of the references, the denoising algorithm will
actually inject noise into the data. I suspect that in some of the
blocks there is some unaccounted noise in your references, which both
deteriorates the results in the concatenated block case, and also
leads to suboptimal results when denoise_pca operates on data that
contains the 'noisy' block.

> Why is this? Am I doing something fundamentally wrong? I'm wondering
> because a colleague of mine has done an almost identical analysis
> step a while ago and she doesn't get problems with high variance
> noise components. I'm not sure whether the problem lies with
> append_data or denoise-pca, but I know that append_data has been
> changed recently, so this might be one possible source of the problem.

I don't think ft_appenddata would be the cause of this, because this
function only concatenates data structures.

As a diagnostic I would check the quality of the reference channel
data first, and see whether there are anomalies across blocks there.

Good luck,
Jan-Mathijs


Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From moratti at MED.UCM.ES  Mon Nov  8 09:17:42 2010
From: moratti at MED.UCM.ES (Stephan Moratti)
Date: Mon, 8 Nov 2010 09:17:42 +0100
Subject: ft_appenddata and denoise_pca causing problems
Message-ID: <MON.8.NOV.2010.091742.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Luisa & Jan-Mathijs

This sounds like a similar problem that I had with 4D data using the
implemented noise reduction algorithm that offers 4D. When there was a very
big noise (like the subject coughing or moving a lot), the noise reduction
resulted in noiser data. I guess this has to do with the global weights
calculation. My solution was to inspect the data if there were data traces
of exceptionally big noise, then I used the 4D tool "mute" where you can set
data traces to zero with a smoothing function for the edges. Doing so, after
noise reduction the data was fine! Maybe something like this can solve your
problem, although I am not sure if it is related to your problem.

Best,

Stephan

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jedmeltzer at YAHOO.COM  Mon Nov  8 18:11:35 2010
From: jedmeltzer at YAHOO.COM (Jed Meltzer)
Date: Mon, 8 Nov 2010 09:11:35 -0800
Subject: Postdoctoral position available in Toronto,
 Neurobiology of Language
In-Reply-To: <FIELDTRIP%201011050005315190.0923@NIC.SURFNET.NL>
Message-ID: <MON.8.NOV.2010.091135.0800.FIELDTRIP@NIC.SURFNET.NL>

A postdoctoral fellowship in neurobiology of language is available in the 
laboratory of Dr. Jed Meltzer, at the Rotman Research Institute, affiliated with 
the University of Toronto.  The fellow will engage in research related to both 
basic language processes and applications to diagnosis and treatment of 
post-stroke aphasia, progressive aphasia, traumatic brain injury, and other 
neurological disorders.  Candidates should have expertise and/or interest in 
some of the following topics:
 
-       - sentence and discourse level comprehension and production
-       - neurorehabilitation in stroke and dementia
-       - frequency domain analysis of EEG/MEG data
-       - multivariate pattern recognition analyses
-       - applications of computational linguistics to neuroscience
-       - quantitative analysis of naturalistic language samples
-       - functional connectivity in fMRI and MEG
 
The Rotman Institute is fully equipped for cognitive neuroscience research, with 
a 3T MRI, 151-channel CTF MEG, several EEG systems, and an excellent 
infrastructure for patient recruitment and testing.  We seek a candidate with 
excellent computational skills, academic knowledge of psycholinguistics, and a 
personal manner suitable for comfortable interactions with elderly patients with 
limited communication abilities.  Prior experience with neuroimaging is helpful 
but not an absolute must. 
 
Toronto is consistently ranked as one of the most livable cities in the world, 
as well as the most multicultural.  It is an excellent place to work for those 
interested in cross-linguistic research, as native speaker populations can be 
found for dozens of world languages. 
 
Applicants should have a recent Ph.D. or M.D. degree, and the potential for 
successfully obtaining external funding.  The postdoctoral position carries a 
term of 2 years and is potentially renewable.  Bursaries are in line with the 
fellowship scales of the Canadian Institutes of Health Research (CIHR) and 
include an allowance for travel and research expenses. A minimum of 80% of each 
fellow’s time will be devoted to research and related activities.
Start date is negotiable, but ideally in the spring of 2011.
 
To apply, please send a current CV and letter of interest to:
Jed Meltzer, Ph.D.
jmeltzer at rotman-baycrest.on.ca
 
Up to three letters of reference may be forwarded to the same address.  Meetings 
and interviews may be arranged at the upcoming Neurobiology of Language and 
Society for Neuroscience conferences in San Diego, although this is certainly 
not required.
 
For more information on the institute, see
 
http://www.rotman-baycrest.on.ca/
 
and for our lab specifically,
 
http://www.rotman-baycrest.on.ca/index.php?section=1093
 
 
 
Jed A. Meltzer
Neurorehabilitation Scientist
Rotman Research Institute - Baycrest Centre
3560 Bathurst Street
Toronto, Ontario, M6A 2E1,CANADA

P: 416 785-2500 x 2117
F: 416 785-2862
C: 647 522-2187
jmeltzer at rotman-baycrest.on.ca





---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101108/47a85f48/attachment.htm>

From batrod at GMAIL.COM  Tue Nov  9 00:48:54 2010
From: batrod at GMAIL.COM (Rodolphe)
Date: Mon, 8 Nov 2010 17:48:54 -0600
Subject: Coherence reference channel for statistical analysis
Message-ID: <MON.8.NOV.2010.174854.0600.FIELDTRIP@NIC.SURFNET.NL>

Dear Fieldtrip users,

i take the liberty to ask again my question to you, as i still didnt find a
solution.
I used ft_connectivityanalysis fuction to get coherence values between every
channels.
I simply wonder how to select a reference channel to make statistical
analysis , like when you can select a reference channel to make a
Topographic plot on coherence values.

Thanks a lot for your help,

Rodolphe.

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101108/c0b6fe4f/attachment.htm>

From sklein at BERKELEY.EDU  Tue Nov  9 10:17:35 2010
From: sklein at BERKELEY.EDU (Stanley Klein)
Date: Tue, 9 Nov 2010 01:17:35 -0800
Subject: Coherence reference channel for statistical analysis
In-Reply-To: <AANLkTim7R9MnaHo-rg2kybf=jVkFoy7JvSi-0TKgZuX_@mail.gmail.com>
Message-ID: <TUE.9.NOV.2010.011735.0800.>

Rodolphe, one interesting option for dealing with the EEG problem of
reference electrode for coherence is to use Laplacians ("current sources")
for each electrode. You may be interested in the pair of papers Winter, et
al. J Neuroscience Methods 166 (2007) and Srinivasan, et al. (Statistics in
Medicine, 26 2007) that my colleague Jian Ding did with Winter, Srinivasan
and Nunez.  They compare Laplacian to regular reference for coherence.

I would think that a good approach would be to do it with several types of
very different references and compare the differences in coherence.

I'm going to be giving a talk on coherence next week at the Neuroscience
meeting in San Diego. I'm going to advocate measuring coherence on
unfiltered data, but using VERY broad-bandwidth Hilbert pair wavelets, very
local in time for doing the coherence. I have several questions on this:
1) Does anyone know whether very broad bandwidth Hilbert pair wavelets have
been used before? In my mind the locality in time is a useful complement to
alternative approaches.

2) Does anyone know whether it has been shown that Morlet and other usual
wavelets are not very pretty when only 1 to 1.5 cycles are present. We use
what we call Cauchy wavelets.

3) Is there a good reference for the connection of cross-correlation to
unnormalized coherence?
Let me define what I mean:
  CC(e1, e2, del) = v(e1, t) v(e2,t-del)           (1)       (using Einstein
summation convention
  Coh(e1, e2, f, n) = V(e1, t,  f, n) V*(e2, t, f, n) , (2) Einstein again
implying sum on t.
where v is the raw EEG, V is the wavelet transform
  V(e, t, f, n) = v(e, t+del) * W(del, f, n),      (3)
where   W(t, f, n) = 1/(1+ i f t)^n               (4)  for complex, Cauchy
Hilbert pair wavelet
e1, e2 are the electrodes (unreferenced preferably with referencing to be
done at end)
t is t, and del is the time shift
f is the peak frequency of the wavelet
n specifies the bandwidth of the wavelet (sqrt(n) is the number of half
cycles)

The connection between CC and Coh would be:
   Coh(e1, e2, f, n) = CC(e1, e2, t+del) *W(del, f', n')   (5)
where  f' and n' are simply connected to f and n but I'm still playing with
this to validate it all.

I'm very interested in learning whether Eq. 5 connecting unnormalized
coherence to cross-correlation is familiar, especially with a pretty closed
form time domain expression for the kernel W(del,f',n') in Eq. 5. The SfN
meeting is soon, which is why I'm eager to learn whether Eq. 5 is well
known. Pretty Hilbert pair filters like W are rare, so I'd be somewhat
surprised if Eq. 5 is commonly used. But I'm new to this coherence business
so I wouldn't be super surprised.

I'd be interested in any feedback. I'll also be happy to meet with anyone
interested in coherence at the SfN meeting or at the preceding
satellite meeting on "Resting State" before SfN.
Stan

On Mon, Nov 8, 2010 at 3:48 PM, Rodolphe <batrod at gmail.com> wrote:

> Dear Fieldtrip users,
>
> i take the liberty to ask again my question to you, as i still didnt find a
> solution.
> I used ft_connectivityanalysis fuction to get coherence values between
> every channels.
> I simply wonder how to select a reference channel to make statistical
> analysis , like when you can select a reference channel to make a
> Topographic plot on coherence values.
>
> Thanks a lot for your help,
>
> Rodolphe.
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101109/4c0ca787/attachment.htm>

From ivana.konvalinka at GMAIL.COM  Tue Nov  9 11:36:45 2010
From: ivana.konvalinka at GMAIL.COM (Ivana Konvalinka)
Date: Tue, 9 Nov 2010 11:36:45 +0100
Subject: Partial Directed Coherence
Message-ID: <TUE.9.NOV.2010.113645.0100.FIELDTRIP@NIC.SURFNET.NL>

Hello,

I was wondering if it would be possible to get more information on partial
directed coherence, using ft_connectivityanalysis. I've been trying to set
it up on the frequency data of pairs of EEG electrodes, by partialling out
motor evoked fields.

Hence, something like this:
cfg.method = 'pdc';
cfg.channelcmb = { pairs of electrodes here };
cfg.partchannel = { electrodes containing fourier spectra of motor events };

pdc1 = ft_connectivityanalysis(cfg, freqs);

I get the following error: "reference to non-existent field 'transfer'".

Is there any more documentation on this method in fieldtrip?

Thanks in advance!

Ivana


--
Ivana Konvalinka
PhD Student
Interacting Minds Group
Center of Functionally Integrative Neuroscience
University of Aarhus
Denmark

http://www.interacting-minds.net
http://www.cfin.au.dk

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101109/8a01911e/attachment.htm>

From jan.schoffelen at DONDERS.RU.NL  Tue Nov  9 11:54:56 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Tue, 9 Nov 2010 11:54:56 +0100
Subject: Partial Directed Coherence
In-Reply-To: <AANLkTi=LYNAUGzQw1PZn_rWO8p-A5d2e+CibxPTy3w4b@mail.gmail.com>
Message-ID: <TUE.9.NOV.2010.115456.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Ivana,

There is not so much information on the fieldtrip wiki as of yet. But
I am working on it.
For the time being, perhaps you know that in order to compute partial
directed coherence, you need to first fit an autoregressive model to
your time domain data. This is necessary to obtain a thing which is
known as the spectral transfer function, from which PDC will be derived.
Therefore you need to do two things before you can call
ft_connectivityanalysis:

use ft_mvaranalysis to obtain the MVAR-model of your data.
use ft_freqanalysis (cfg.method = 'mvar') to obtain the spectral
transfer function.

Note that you do not need to specify partchannel when you will be
computing pdc; the idea is that by fitting a multivariate model to all
channels of interest, the 'partialisation' is achieved. At least
that's the theory...

I hope to find time to work on the documentation soon.

Best wishes,

Jan-Mathijs


On Nov 9, 2010, at 11:36 AM, Ivana Konvalinka wrote:

> Hello,
>
> I was wondering if it would be possible to get more information on
> partial directed coherence, using ft_connectivityanalysis. I've been
> trying to set it up on the frequency data of pairs of EEG
> electrodes, by partialling out motor evoked fields.
>
> Hence, something like this:
> cfg.method = 'pdc';
> cfg.channelcmb = { pairs of electrodes here };
> cfg.partchannel = { electrodes containing fourier spectra of motor
> events };
>
> pdc1 = ft_connectivityanalysis(cfg, freqs);
>
> I get the following error: "reference to non-existent field
> 'transfer'".
>
> Is there any more documentation on this method in fieldtrip?
>
> Thanks in advance!
>
> Ivana
>
>
> --
> Ivana Konvalinka
> PhD Student
> Interacting Minds Group
> Center of Functionally Integrative Neuroscience
> University of Aarhus
> Denmark
>
> http://www.interacting-minds.net
> http://www.cfin.au.dk
>
> --------------------------------------------------------------------------- You
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101109/0ffc937d/attachment.htm>

From ivana.konvalinka at GMAIL.COM  Tue Nov  9 13:35:08 2010
From: ivana.konvalinka at GMAIL.COM (Ivana Konvalinka)
Date: Tue, 9 Nov 2010 13:35:08 +0100
Subject: Partial Directed Coherence
In-Reply-To: <59C5E4F5-F1E9-480A-AD91-6E0B7C02A1F2@donders.ru.nl>
Message-ID: <TUE.9.NOV.2010.133508.0100.FIELDTRIP@NIC.SURFNET.NL>

Thanks Jan-Mathijs, that makes sense.

One more question - is it possible to just do partial coherence in
fieldtrip?

Best wishes,

Ivana



On Tue, Nov 9, 2010 at 11:54 AM, jan-mathijs schoffelen <
jan.schoffelen at donders.ru.nl> wrote:

> Dear Ivana,
>
> There is not so much information on the fieldtrip wiki as of yet. But I am
> working on it.
> For the time being, perhaps you know that in order to compute partial
> directed coherence, you need to first fit an autoregressive model to your
> time domain data. This is necessary to obtain a thing which is known as the
> spectral transfer function, from which PDC will be derived.
> Therefore you need to do two things before you can call
> ft_connectivityanalysis:
>
> use ft_mvaranalysis to obtain the MVAR-model of your data.
> use ft_freqanalysis (cfg.method = 'mvar') to obtain the spectral transfer
> function.
>
> Note that you do not need to specify partchannel when you will be computing
> pdc; the idea is that by fitting a multivariate model to all channels of
> interest, the 'partialisation' is achieved. At least that's the theory...
>
> I hope to find time to work on the documentation soon.
>
> Best wishes,
>
> Jan-Mathijs
>
>
> On Nov 9, 2010, at 11:36 AM, Ivana Konvalinka wrote:
>
> Hello,
>
> I was wondering if it would be possible to get more information on partial
> directed coherence, using ft_connectivityanalysis. I've been trying to set
> it up on the frequency data of pairs of EEG electrodes, by partialling out
> motor evoked fields.
>
> Hence, something like this:
> cfg.method = 'pdc';
> cfg.channelcmb = { pairs of electrodes here };
> cfg.partchannel = { electrodes containing fourier spectra of motor events
> };
>
> pdc1 = ft_connectivityanalysis(cfg, freqs);
>
> I get the following error: "reference to non-existent field 'transfer'".
>
> Is there any more documentation on this method in fieldtrip?
>
> Thanks in advance!
>
> Ivana
>
>
> --
> Ivana Konvalinka
> PhD Student
> Interacting Minds Group
> Center of Functionally Integrative Neuroscience
> University of Aarhus
> Denmark
>
> http://www.interacting-minds.net
> http://www.cfin.au.dk
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>
>
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl
> Telephone: 0031-24-3614793
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>



--
Ivana Konvalinka
PhD Student
Interacting Minds Group
Center of Functionally Integrative Neuroscience
University of Aarhus
Denmark

http://www.interacting-minds.net
http://www.cfin.au.dk

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101109/a6eb1672/attachment.htm>

From l.frei at PSY.GLA.AC.UK  Wed Nov 10 13:12:13 2010
From: l.frei at PSY.GLA.AC.UK (Luisa Frei)
Date: Wed, 10 Nov 2010 12:12:13 +0000
Subject: ft_appenddata and denoise_pca causing problems
In-Reply-To: <0DA2C32A-5511-42A3-A968-045B695B0311@donders.ru.nl>
Message-ID: <WED.10.NOV.2010.121213.0000.FIELDTRIP@NIC.SURFNET.NL>

Hi Jan-Mathijs,
thanks for the reply. I have now resorted to denoising per block,
which gets rid of most of the noise components (although there is
usually one left per session, which is nothing to worry about, I've
been told). I have also visually inspected the blocks for one session
to make sure there are no jumps left and reduced the threshold for
jump artifacts. However, this didn't make much of a difference at all.

We discussed this in our MEG group meeting and I found out that one
other person had had the same problem, whereas another colleague
didn't have this problem, but she had used the old version of
ft_append_data. We thought, that if this keeps happening, it might be
worth taking a look at ft_append_data, to make sure it handles 4D
reference channels correctly. For now however, I'm happy with the
solution I have.

Thanks,
Luisa

On 8 Nov 2010, at 08:07, jan-mathijs schoffelen wrote:

> Dear Luisa,
>
>>
>> Hi,
>> I'm sorry if this has been discussed before and if it has, could
>> you please direct me to the relevant emails? Thanks.
>>
> Don't worry. This has not yet been discussed here before, and it's
> an interesting issue. Yet, probably most people wouldn't know what
> you are talking about, because the function denoise_pca is not yet
> part of the FieldTrip release version ;o). At the moment, it's only
> the CCNi and the fcdc who have it available.
>
>> I am encountering a problem when using ft_appenddata and
>> denoise_pca. My MEG experiment  (4D) consists of 10 blocks per
>> session, for each of which I have a separate data set.
>>
>> During preprocessing (after artifact rejection), I concatenate
>> these data sets to find denoising weights per session using the
>> function denoise_pca for 4D (I do this on shorter 400 ms epochs to
>> save computational power). Afterwards, I apply these weights per
>> block, downsample the data and concatenate the resulting data
>> again in order to do an ICA per session to remove heart beat
>> artifacts. I downsample because I use longer epochs to do that
>> (1.5 sec).
>> However, when I do an ICA on the denoised and concatenated
>> session, I get lots of high variance noise components (first figure):
>> Trying to find the root of this, I went back and did this analysis
>> for one block only (denoising for one block, no concatenating) and
>> the result looks much better (second figure):
>> Then, as a test, I tried to concatenate two blocks, find the
>> weights for those two concatenated blocks, apply them to the
>> individual blocks, concatenate again and do the ICA on these two
>> blocks and I get this (last figure):
>> So, it seems like when denoising per session (the concatenated
>> blocks), I introduce noise when I apply the pca weights to the
>> individual blocks. Whereas the whole point of the exercise was to
>> reduce noise by denoising per session rather than block.
>
> Denoise_pca indeed tries to reduce the noise in the magnetometer
> data by computing a set of balancing coefficients, which are used
> to subtract a weighted combination of the signals measured at the
> reference sensors from the signals measured at the magnetometer
> coils. As such, it is assumed that the signals picked up by the
> references reflect purely environmental noise. If there is sensor
> specific noise, e.g. a jump in one of the references, the denoising
> algorithm will actually inject noise into the data. I suspect that
> in some of the blocks there is some unaccounted noise in your
> references, which both deteriorates the results in the concatenated
> block case, and also leads to suboptimal results when denoise_pca
> operates on data that contains the 'noisy' block.
>
>> Why is this? Am I doing something fundamentally wrong? I'm
>> wondering because a colleague of mine has done an almost identical
>> analysis step a while ago and she doesn't get problems with high
>> variance noise components. I'm not sure whether the problem lies
>> with append_data or denoise-pca, but I know that append_data has
>> been changed recently, so this might be one possible source of the
>> problem.
>
> I don't think ft_appenddata would be the cause of this, because
> this function only concatenates data structures.
>
> As a diagnostic I would check the quality of the reference channel
> data first, and see whether there are anomalies across blocks there.
>
> Good luck,
> Jan-Mathijs
>
>
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl
> Telephone: 0031-24-3614793
>
> ----------------------------------------------------------------------
> -----
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ----------------------------------------------------------------------
> -----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From batrod at GMAIL.COM  Wed Nov 10 19:08:58 2010
From: batrod at GMAIL.COM (Rodolphe Nenert)
Date: Wed, 10 Nov 2010 19:08:58 +0100
Subject: Coherence reference channel for statistical analysis
Message-ID: <WED.10.NOV.2010.190858.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Stanley, 

thanks for this very interesting point. Actually i cant go to SFN but my boss 
will, and i asked her to go to your talk!
Anyway, i was in fact looking for a practical way to select a reference channel 
with Fieldtrip function ft_freqstatistics.
The function connectivityanalysis calculated coherence between all possible 
channel-pair of electrodes. 
But i dont want to make statistical analysis on all possible pairs, so i was 
looking for a cfg parameter in order to select a ref.
Actually, i copied the the part of the Topographic plot that does that, by 
searching the name of the specified ref electrode in all pairs and then redraw 
the matrix with only concerned pairs.


 



On Tue, 9 Nov 2010 01:17:35 -0800, Stanley Klein <sklein at BERKELEY.EDU> 
wrote:

>Rodolphe, one interesting option for dealing with the EEG problem of
>reference electrode for coherence is to use Laplacians ("current sources")
>for each electrode. You may be interested in the pair of papers Winter, et
>al. J Neuroscience Methods 166 (2007) and Srinivasan, et al. (Statistics in
>Medicine, 26 2007) that my colleague Jian Ding did with Winter, Srinivasan
>and Nunez.  They compare Laplacian to regular reference for coherence.
>
>I would think that a good approach would be to do it with several types of
>very different references and compare the differences in coherence.
>
>I'm going to be giving a talk on coherence next week at the Neuroscience
>meeting in San Diego. I'm going to advocate measuring coherence on
>unfiltered data, but using VERY broad-bandwidth Hilbert pair wavelets, very
>local in time for doing the coherence. I have several questions on this:
>1) Does anyone know whether very broad bandwidth Hilbert pair wavelets 
have
>been used before? In my mind the locality in time is a useful complement to
>alternative approaches.
>
>2) Does anyone know whether it has been shown that Morlet and other usual
>wavelets are not very pretty when only 1 to 1.5 cycles are present. We use
>what we call Cauchy wavelets.
>
>3) Is there a good reference for the connection of cross-correlation to
>unnormalized coherence?
>Let me define what I mean:
>  CC(e1, e2, del) = v(e1, t) v(e2,t-del)           (1)       (using Einstein
>summation convention
>  Coh(e1, e2, f, n) = V(e1, t,  f, n) V*(e2, t, f, n) , (2) Einstein again
>implying sum on t.
>where v is the raw EEG, V is the wavelet transform
>  V(e, t, f, n) = v(e, t+del) * W(del, f, n),      (3)
>where   W(t, f, n) = 1/(1+ i f t)^n               (4)  for complex, Cauchy
>Hilbert pair wavelet
>e1, e2 are the electrodes (unreferenced preferably with referencing to be
>done at end)
>t is t, and del is the time shift
>f is the peak frequency of the wavelet
>n specifies the bandwidth of the wavelet (sqrt(n) is the number of half
>cycles)
>
>The connection between CC and Coh would be:
>   Coh(e1, e2, f, n) = CC(e1, e2, t+del) *W(del, f', n')   (5)
>where  f' and n' are simply connected to f and n but I'm still playing with
>this to validate it all.
>
>I'm very interested in learning whether Eq. 5 connecting unnormalized
>coherence to cross-correlation is familiar, especially with a pretty closed
>form time domain expression for the kernel W(del,f',n') in Eq. 5. The SfN
>meeting is soon, which is why I'm eager to learn whether Eq. 5 is well
>known. Pretty Hilbert pair filters like W are rare, so I'd be somewhat
>surprised if Eq. 5 is commonly used. But I'm new to this coherence business
>so I wouldn't be super surprised.
>
>I'd be interested in any feedback. I'll also be happy to meet with anyone
>interested in coherence at the SfN meeting or at the preceding
>satellite meeting on "Resting State" before SfN.
>Stan
>
>On Mon, Nov 8, 2010 at 3:48 PM, Rodolphe <batrod at gmail.com> wrote:
>
>> Dear Fieldtrip users,
>>
>> i take the liberty to ask again my question to you, as i still didnt find a
>> solution.
>> I used ft_connectivityanalysis fuction to get coherence values between
>> every channels.
>> I simply wonder how to select a reference channel to make statistical
>> analysis , like when you can select a reference channel to make a
>> Topographic plot on coherence values.
>>
>> Thanks a lot for your help,
>>
>> Rodolphe.
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the FieldTrip list. The aim of this list is to facilitate the discussion
>> between users of the FieldTrip toolbox, to share experiences
>> and to discuss new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>>
>
>---------------------------------------------------------------------------
>You are receiving this message because you are subscribed to
>the  FieldTrip list. The aim of this list is to facilitate the discussion
>between  users of the FieldTrip  toolbox, to share experiences
>and to discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>---------------------------------------------------------------------------
>

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From cerisa.stawowsky at ONLINE.DE  Tue Nov 16 17:03:13 2010
From: cerisa.stawowsky at ONLINE.DE (Cerisa Stawowsky)
Date: Tue, 16 Nov 2010 17:03:13 +0100
Subject: problems with artifact correction after ICA
Message-ID: <TUE.16.NOV.2010.170313.0100.FIELDTRIP@NIC.SURFNET.NL>

An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101116/74f22af8/attachment.htm>
-------------- next part --------------

Dear Fieldtrip user,

I used for my EEG-Data ICA to detect eye blinks. I remove the bad components and get 'cleaned' trials.
After ICA I want to use artifact correction for muscle artifacts, with following inputs:

DataAfterICATest =

 label: {128x1 cell}
 fsample: 1000
 trial: {1x39 cell}
 time: {1x39 cell}

trl = DataAfterICATest.sampleinfo

sampleinfo: [39x2 double]


cfg=[];
cfg.trl = trl
cfg.artfctdef.muscle.trlpadding = 0.1
cfg.artfctdef.muscle.sgn = 'EEG'; % selection of valid channels
cfg.artfctdef.muscle.bpfreq = [110 140];
cfg.artfctdef.muscle.cutoff = 4; % default = 4
cfg = ft_artifact_muscle(cfg,DataAfterICATest); % automatic muscle activity rejection

I get following errors:

Error in ==> ft_fetch_data at 109
 count = count(begsample:endsample);

Error in ==> ft_artifact_zvalue at 163
 dat{trlop} = ft_fetch_data(data, 'header', hdr, 'begsample', trl(trlop,1)-fltpadding, 'endsample',
 trl(trlop,2)+fltpadding, 'chanindx', sgnind, 'checkboundary', strcmp(cfg.continuous,'no')
Error in ==> ft_artifact_muscle at 152
 [tmpcfg, artifact] = ft_artifact_zvalue(tmpcfg, data);

Have somebody experience with artifact correction after ICA or with trials?


Best regards,

Cerisa Stawowsky


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

From jan.schoffelen at DONDERS.RU.NL  Wed Nov 17 09:49:56 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Wed, 17 Nov 2010 09:49:56 +0100
Subject: Partial Directed Coherence
In-Reply-To: <AANLkTinDwX=OYA=g8A-oqne4Dh7jXTuTLMsXEWwSPVuC@mail.gmail.com>
Message-ID: <WED.17.NOV.2010.094956.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Ivana,

Yes, it is possible to compute partial coherence. As already
mentioned, I am working on the documentation, but if you are bold
enough to give it a try you may want to look into the code of
ft_connectivityanalysis. What is needed for sure is a field
cfg.partchannel, containing the channel(s) which will be partialized
out. Probably things will work out of the box when the input to
ft_connectivityanalysis as obtained with ft_freqanalysis was generated
with cfg.output = 'fourier'.

Best wishes,

Jan-Mathijs


On Nov 9, 2010, at 1:35 PM, Ivana Konvalinka wrote:

> Thanks Jan-Mathijs, that makes sense.
>
> One more question - is it possible to just do partial coherence in
> fieldtrip?
>
> Best wishes,
>
> Ivana
>
>
>
> On Tue, Nov 9, 2010 at 11:54 AM, jan-mathijs schoffelen <jan.schoffelen at donders.ru.nl
> > wrote:
> Dear Ivana,
>
> There is not so much information on the fieldtrip wiki as of yet.
> But I am working on it.
> For the time being, perhaps you know that in order to compute
> partial directed coherence, you need to first fit an autoregressive
> model to your time domain data. This is necessary to obtain a thing
> which is known as the spectral transfer function, from which PDC
> will be derived.
> Therefore you need to do two things before you can call
> ft_connectivityanalysis:
>
> use ft_mvaranalysis to obtain the MVAR-model of your data.
> use ft_freqanalysis (cfg.method = 'mvar') to obtain the spectral
> transfer function.
>
> Note that you do not need to specify partchannel when you will be
> computing pdc; the idea is that by fitting a multivariate model to
> all channels of interest, the 'partialisation' is achieved. At least
> that's the theory...
>
> I hope to find time to work on the documentation soon.
>
> Best wishes,
>
> Jan-Mathijs
>
>
> On Nov 9, 2010, at 11:36 AM, Ivana Konvalinka wrote:
>
>> Hello,
>>
>> I was wondering if it would be possible to get more information on
>> partial directed coherence, using ft_connectivityanalysis. I've
>> been trying to set it up on the frequency data of pairs of EEG
>> electrodes, by partialling out motor evoked fields.
>>
>> Hence, something like this:
>> cfg.method = 'pdc';
>> cfg.channelcmb = { pairs of electrodes here };
>> cfg.partchannel = { electrodes containing fourier spectra of motor
>> events };
>>
>> pdc1 = ft_connectivityanalysis(cfg, freqs);
>>
>> I get the following error: "reference to non-existent field
>> 'transfer'".
>>
>> Is there any more documentation on this method in fieldtrip?
>>
>> Thanks in advance!
>>
>> Ivana
>>
>>
>> --
>> Ivana Konvalinka
>> PhD Student
>> Interacting Minds Group
>> Center of Functionally Integrative Neuroscience
>> University of Aarhus
>> Denmark
>>
>> http://www.interacting-minds.net
>> http://www.cfin.au.dk
>>
>> --------------------------------------------------------------------------- You
>>  are receiving this message because you are subscribed to
>> the FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between users of the FieldTrip toolbox, to share experiences
>> and to discuss new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>>
>
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl
> Telephone: 0031-24-3614793
>
> --------------------------------------------------------------------------- You
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>
>
>
>
> --
> Ivana Konvalinka
> PhD Student
> Interacting Minds Group
> Center of Functionally Integrative Neuroscience
> University of Aarhus
> Denmark
>
> http://www.interacting-minds.net
> http://www.cfin.au.dk
>
> --------------------------------------------------------------------------- You
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101117/bdcedefc/attachment.htm>

From jan.schoffelen at DONDERS.RU.NL  Wed Nov 17 09:53:42 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Wed, 17 Nov 2010 09:53:42 +0100
Subject: ft_appenddata and denoise_pca causing problems
In-Reply-To: <B5E85D60-9325-4CF5-A90A-843445C968EC@psy.gla.ac.uk>
Message-ID: <WED.17.NOV.2010.095342.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi Luisa,

When discussing your problem with Joachim, he also mentioned the
ft_appenddata issue. I'd find it really strange if a change in
ft_appenddata would cause your problems. As such, ft_appenddata does
not make a distinction between different types of MEG-channels
(references or magnetometers). One way to check whether ft_appenddata
is the bad guy would be to let your colleague without the problems run
with a (recommended) recent version of fieldtrip.

Best,

Jan-Mathijs


On Nov 10, 2010, at 1:12 PM, Luisa Frei wrote:

> Hi Jan-Mathijs,
> thanks for the reply. I have now resorted to denoising per block,
> which gets rid of most of the noise components (although there is
> usually one left per session, which is nothing to worry about, I've
> been told). I have also visually inspected the blocks for one
> session to make sure there are no jumps left and reduced the
> threshold for jump artifacts. However, this didn't make much of a
> difference at all.
>
> We discussed this in our MEG group meeting and I found out that one
> other person had had the same problem, whereas another colleague
> didn't have this problem, but she had used the old version of
> ft_append_data. We thought, that if this keeps happening, it might
> be worth taking a look at ft_append_data, to make sure it handles 4D
> reference channels correctly. For now however, I'm happy with the
> solution I have.
>
> Thanks,
> Luisa
>
> On 8 Nov 2010, at 08:07, jan-mathijs schoffelen wrote:
>
>> Dear Luisa,
>>
>>>
>>> Hi,
>>> I'm sorry if this has been discussed before and if it has, could
>>> you please direct me to the relevant emails? Thanks.
>>>
>> Don't worry. This has not yet been discussed here before, and it's
>> an interesting issue. Yet, probably most people wouldn't know what
>> you are talking about, because the function denoise_pca is not yet
>> part of the FieldTrip release version ;o). At the moment, it's only
>> the CCNi and the fcdc who have it available.
>>
>>> I am encountering a problem when using ft_appenddata and
>>> denoise_pca. My MEG experiment  (4D) consists of 10 blocks per
>>> session, for each of which I have a separate data set.
>>>
>>> During preprocessing (after artifact rejection), I concatenate
>>> these data sets to find denoising weights per session using the
>>> function denoise_pca for 4D (I do this on shorter 400 ms epochs to
>>> save computational power). Afterwards, I apply these weights per
>>> block, downsample the data and concatenate the resulting data
>>> again in order to do an ICA per session to remove heart beat
>>> artifacts. I downsample because I use longer epochs to do that
>>> (1.5 sec).
>>> However, when I do an ICA on the denoised and concatenated
>>> session, I get lots of high variance noise components (first
>>> figure):
>>> Trying to find the root of this, I went back and did this analysis
>>> for one block only (denoising for one block, no concatenating) and
>>> the result looks much better (second figure):
>>> Then, as a test, I tried to concatenate two blocks, find the
>>> weights for those two concatenated blocks, apply them to the
>>> individual blocks, concatenate again and do the ICA on these two
>>> blocks and I get this (last figure):
>>> So, it seems like when denoising per session (the concatenated
>>> blocks), I introduce noise when I apply the pca weights to the
>>> individual blocks. Whereas the whole point of the exercise was to
>>> reduce noise by denoising per session rather than block.
>>
>> Denoise_pca indeed tries to reduce the noise in the magnetometer
>> data by computing a set of balancing coefficients, which are used
>> to subtract a weighted combination of the signals measured at the
>> reference sensors from the signals measured at the magnetometer
>> coils. As such, it is assumed that the signals picked up by the
>> references reflect purely environmental noise. If there is sensor
>> specific noise, e.g. a jump in one of the references, the denoising
>> algorithm will actually inject noise into the data. I suspect that
>> in some of the blocks there is some unaccounted noise in your
>> references, which both deteriorates the results in the concatenated
>> block case, and also leads to suboptimal results when denoise_pca
>> operates on data that contains the 'noisy' block.
>>
>>> Why is this? Am I doing something fundamentally wrong? I'm
>>> wondering because a colleague of mine has done an almost identical
>>> analysis step a while ago and she doesn't get problems with high
>>> variance noise components. I'm not sure whether the problem lies
>>> with append_data or denoise-pca, but I know that append_data has
>>> been changed recently, so this might be one possible source of the
>>> problem.
>>
>> I don't think ft_appenddata would be the cause of this, because
>> this function only concatenates data structures.
>>
>> As a diagnostic I would check the quality of the reference channel
>> data first, and see whether there are anomalies across blocks there.
>>
>> Good luck,
>> Jan-Mathijs
>>
>>
>> Dr. J.M. (Jan-Mathijs) Schoffelen
>> Donders Institute for Brain, Cognition and Behaviour,
>> Centre for Cognitive Neuroimaging,
>> Radboud University Nijmegen, The Netherlands
>> J.Schoffelen at donders.ru.nl
>> Telephone: 0031-24-3614793
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jan.schoffelen at DONDERS.RU.NL  Wed Nov 17 09:56:35 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Wed, 17 Nov 2010 09:56:35 +0100
Subject: Coherence reference channel for statistical analysis
In-Reply-To: <LISTSERV%201011101908587050.7C78@NIC.SURFNET.NL>
Message-ID: <WED.17.NOV.2010.095635.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Rodolphe,

If you have good a priori reasons to only do statistics on a subset of
channel pairs, you may want to constrain ft_connectivityanalysis into
not computing the full NxN coherence matrix. This is possible when you
provide ft_connecitivityanalysis with a field cfg.channelcmb,
specifying the combinations which you would like to compute. Some more
information can be found also in ft_channelcombination. To make it
work smoothly, it is optimal to provide ft_connecitvityanalysis with a
frequency structure containing fourier coefficients
(cfg.output='fourier' prior to calling ft_freqanalysis).

Best

JM


On Nov 10, 2010, at 7:08 PM, Rodolphe Nenert wrote:

> Dear Stanley,
>
> thanks for this very interesting point. Actually i cant go to SFN
> but my boss
> will, and i asked her to go to your talk!
> Anyway, i was in fact looking for a practical way to select a
> reference channel
> with Fieldtrip function ft_freqstatistics.
> The function connectivityanalysis calculated coherence between all
> possible
> channel-pair of electrodes.
> But i dont want to make statistical analysis on all possible pairs,
> so i was
> looking for a cfg parameter in order to select a ref.
> Actually, i copied the the part of the Topographic plot that does
> that, by
> searching the name of the specified ref electrode in all pairs and
> then redraw
> the matrix with only concerned pairs.
>
>
>
>
>
>
> On Tue, 9 Nov 2010 01:17:35 -0800, Stanley Klein <sklein at BERKELEY.EDU>
> wrote:
>
>> Rodolphe, one interesting option for dealing with the EEG problem of
>> reference electrode for coherence is to use Laplacians ("current
>> sources")
>> for each electrode. You may be interested in the pair of papers
>> Winter, et
>> al. J Neuroscience Methods 166 (2007) and Srinivasan, et al.
>> (Statistics in
>> Medicine, 26 2007) that my colleague Jian Ding did with Winter,
>> Srinivasan
>> and Nunez.  They compare Laplacian to regular reference for
>> coherence.
>>
>> I would think that a good approach would be to do it with several
>> types of
>> very different references and compare the differences in coherence.
>>
>> I'm going to be giving a talk on coherence next week at the
>> Neuroscience
>> meeting in San Diego. I'm going to advocate measuring coherence on
>> unfiltered data, but using VERY broad-bandwidth Hilbert pair
>> wavelets, very
>> local in time for doing the coherence. I have several questions on
>> this:
>> 1) Does anyone know whether very broad bandwidth Hilbert pair
>> wavelets
> have
>> been used before? In my mind the locality in time is a useful
>> complement to
>> alternative approaches.
>>
>> 2) Does anyone know whether it has been shown that Morlet and other
>> usual
>> wavelets are not very pretty when only 1 to 1.5 cycles are present.
>> We use
>> what we call Cauchy wavelets.
>>
>> 3) Is there a good reference for the connection of cross-
>> correlation to
>> unnormalized coherence?
>> Let me define what I mean:
>> CC(e1, e2, del) = v(e1, t) v(e2,t-del)           (1)       (using
>> Einstein
>> summation convention
>> Coh(e1, e2, f, n) = V(e1, t,  f, n) V*(e2, t, f, n) , (2) Einstein
>> again
>> implying sum on t.
>> where v is the raw EEG, V is the wavelet transform
>> V(e, t, f, n) = v(e, t+del) * W(del, f, n),      (3)
>> where   W(t, f, n) = 1/(1+ i f t)^n               (4)  for complex,
>> Cauchy
>> Hilbert pair wavelet
>> e1, e2 are the electrodes (unreferenced preferably with referencing
>> to be
>> done at end)
>> t is t, and del is the time shift
>> f is the peak frequency of the wavelet
>> n specifies the bandwidth of the wavelet (sqrt(n) is the number of
>> half
>> cycles)
>>
>> The connection between CC and Coh would be:
>>  Coh(e1, e2, f, n) = CC(e1, e2, t+del) *W(del, f', n')   (5)
>> where  f' and n' are simply connected to f and n but I'm still
>> playing with
>> this to validate it all.
>>
>> I'm very interested in learning whether Eq. 5 connecting unnormalized
>> coherence to cross-correlation is familiar, especially with a
>> pretty closed
>> form time domain expression for the kernel W(del,f',n') in Eq. 5.
>> The SfN
>> meeting is soon, which is why I'm eager to learn whether Eq. 5 is
>> well
>> known. Pretty Hilbert pair filters like W are rare, so I'd be
>> somewhat
>> surprised if Eq. 5 is commonly used. But I'm new to this coherence
>> business
>> so I wouldn't be super surprised.
>>
>> I'd be interested in any feedback. I'll also be happy to meet with
>> anyone
>> interested in coherence at the SfN meeting or at the preceding
>> satellite meeting on "Resting State" before SfN.
>> Stan
>>
>> On Mon, Nov 8, 2010 at 3:48 PM, Rodolphe <batrod at gmail.com> wrote:
>>
>>> Dear Fieldtrip users,
>>>
>>> i take the liberty to ask again my question to you, as i still
>>> didnt find a
>>> solution.
>>> I used ft_connectivityanalysis fuction to get coherence values
>>> between
>>> every channels.
>>> I simply wonder how to select a reference channel to make
>>> statistical
>>> analysis , like when you can select a reference channel to make a
>>> Topographic plot on coherence values.
>>>
>>> Thanks a lot for your help,
>>>
>>> Rodolphe.
>>>
>>> ---------------------------------------------------------------------------
>>> You are receiving this message because you are subscribed to
>>> the FieldTrip list. The aim of this list is to facilitate the
>>> discussion
>>> between users of the FieldTrip toolbox, to share experiences
>>> and to discuss new ideas for MEG and EEG analysis.
>>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>> ---------------------------------------------------------------------------
>>>
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>>
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jan.schoffelen at DONDERS.RU.NL  Wed Nov 17 15:52:06 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Wed, 17 Nov 2010 15:52:06 +0100
Subject: ft_denoise_pca
Message-ID: <WED.17.NOV.2010.155206.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear all,

I just added a new function to the svn-repository, making it available
in the daily download as of tonight. This function is called
ft_denoise_pca and deals with the denoising of MEG data based on
concurrent measurements on reference sensors. The algorithm is
inspired by the denoising technique applied in the 4D neuroimaging
software, but can be applied whenever there are reference channel
measurements available. I allows for the computation (and application)
of balancing weights by regressing specified reference channels out of
the MEG data. There have been some recent threads on this discussion
list about this issue.

For those interested in using it: happy computing.

For those already using it: please revert to using the new version
which comes with your regular updates of fieldtrip. This version is
also not dependent anymore on the bunch of cellfunctions, because I
copied them as subfunctions into the main body of the code for the
time being.

Best wishes,

Jan-Mathijs

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From sander at MPIB-BERLIN.MPG.DE  Thu Nov 18 15:48:43 2010
From: sander at MPIB-BERLIN.MPG.DE (Sander, Myriam)
Date: Thu, 18 Nov 2010 15:48:43 +0100
Subject: Testing for an interaction effect with more than 1 ivar using
 depsamplesF
Message-ID: <THU.18.NOV.2010.154843.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Fieldtrip-Users, 

 

I would like to test for an interaction effect in a within-subject
experiment. I know there was a similar question by Tzvetan Popov this
year, but I did not find an answer to his question in the archives, so I
would like to ask this again. 
  

 I have 5 subjects and 2 within-factors, one with 2 levels and one with
3 levels. 

I specified the design matrix as

 

1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5

1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2

1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3

 

clusterstatcfg.ivar   = [2,3];

clusterstatcfg.uvar   = 1;

 

I want to use freqstatistics with depsamplesF using montecarlo / cluster
as correction method, but I get the following error: 

Error using ==> statfun_depsamplesF at 110

Invalid specification of the design array.

 

The problem seems to me that depsamplesF only allows for 1 ivar, but not
two - is that right? 

 

Is there a way how to test interaction effects in this way? Or is it
necessary to first take the difference between the 2 levels of the first
factors and then only test for the effect of the second factor? 

 

Thanks a lot for your help, 

Myriam 

 

______________________________________

 

Myriam Sander, Dipl.-Psych.

Predoctoral Research Fellow

Center for Lifespan Psychology

Max Planck Institute for Human Development

Lentzeallee 94

14195 Berlin Germany

 

Office Phone: (49) 30-82406-414

Fax: (49) 30-8249939

 

sander at mpib-berlin.mpg.de <mailto:sander at mpib-berlin.mpg.de> 

______________________________________

 


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101118/a7b05c2e/attachment.htm>

From chavera at GMX.DE  Thu Nov 18 18:01:56 2010
From: chavera at GMX.DE (Saskia Helbling)
Date: Thu, 18 Nov 2010 18:01:56 +0100
Subject: Testing for an interaction effect with more than 1 ivar using
 depsamplesF
In-Reply-To: <82EE999347EBF142A8D78EF16FB83D8D01EDBD56@MPIBMAIL01.mpib-berlin.mpg.de>
Message-ID: <THU.18.NOV.2010.180156.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Myriam,

earlier threads about 2-way ANOVA can be found here:
https://listserv.surfnet.nl/scripts/wa.cgi?A2=ind1009&L=FIELDTRIP&P=R11455
or here:
https://listserv.surfnet.nl/scripts/wa.cgi?A2=ind0911&L=FIELDTRIP&P=R2726

You are right, depsamplesF accepts only one independent variable and therefor only works for a 1-way ANOVA.

It is not possible to construct an exact permutation test for an interaction, as you'd have to restrict permutations within the levels of the main effects - which leaves you with no exchangeable units you may permute.

There are approximate tests, though. The paper of Anderson et al was posted here already, but since I found it very useful, I cite it again: Anderson MJ and Ter Braak CJF, "PERMUTATION TESTS FOR MULTI-FACTORIAL ANALYSIS OF VARIANCE", J Statistical Computation and Simulation, 2003.

The easiest way to do an approximate test mentioned there, would be Manly's approach of unrestricted (not limited to occur only within levels) permutations of the raw data (raw meaning you do not subtract any cell means). There are more sophisticated approaches, as restricted permutation of residuals, with higher power and a more intuitive justification. However, unrestricted permutations are easiest to implement.

You can start with the statfun_depsamplesF function, which would give you  a suitable data structure (with unrestricted permutations), and feed this data into your ANOVA model (I used the resampling_statistical_toolkit of Delorme). You'll have to adapt the critical values, dfs & the probabilities with respect to the interaction effect. Then you just test your found interaction effect against your "interaction effect distribution" gained by the permutations - as usually.

Approximate tests haven't been discussed at this list, as far as I know, I'd highly appreciate any objections/comments on this topic.

Thanks in advance, best Saskia



--

Saskia Helbling
Institute of Medical Psychology
Goethe University
Frankfurt am Main, Germany
Tel. +49-69-63015661
Fax. +49-69-63017606



-------- Original-Nachricht --------
> Datum: Thu, 18 Nov 2010 15:48:43 +0100
> Von: "Sander, Myriam" <sander at MPIB-BERLIN.MPG.DE>
> An: FIELDTRIP at NIC.SURFNET.NL
> Betreff: [FIELDTRIP] Testing for an interaction effect with more than 1 ivar using depsamplesF

> Dear Fieldtrip-Users,
>
>
>
> I would like to test for an interaction effect in a within-subject
> experiment. I know there was a similar question by Tzvetan Popov this
> year, but I did not find an answer to his question in the archives, so I
> would like to ask this again.
>
>
>  I have 5 subjects and 2 within-factors, one with 2 levels and one with
> 3 levels.
>
> I specified the design matrix as
>
>
>
> 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5
>
> 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2
>
> 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3
>
>
>
> clusterstatcfg.ivar   = [2,3];
>
> clusterstatcfg.uvar   = 1;
>
>
>
> I want to use freqstatistics with depsamplesF using montecarlo / cluster
> as correction method, but I get the following error:
>
> Error using ==> statfun_depsamplesF at 110
>
> Invalid specification of the design array.
>
>
>
> The problem seems to me that depsamplesF only allows for 1 ivar, but not
> two - is that right?
>
>
>
> Is there a way how to test interaction effects in this way? Or is it
> necessary to first take the difference between the 2 levels of the first
> factors and then only test for the effect of the second factor?
>
>
>
> Thanks a lot for your help,
>
> Myriam
>
>
>
> ______________________________________
>
>
>
> Myriam Sander, Dipl.-Psych.
>
> Predoctoral Research Fellow
>
> Center for Lifespan Psychology
>
> Max Planck Institute for Human Development
>
> Lentzeallee 94
>
> 14195 Berlin Germany
>
>
>
> Office Phone: (49) 30-82406-414
>
> Fax: (49) 30-8249939
>
>
>
> sander at mpib-berlin.mpg.de <mailto:sander at mpib-berlin.mpg.de>
>
> ______________________________________
>
>
>
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From manish.saggar at GMAIL.COM  Sat Nov 20 08:20:36 2010
From: manish.saggar at GMAIL.COM (Manish Saggar)
Date: Sat, 20 Nov 2010 01:20:36 -0600
Subject: avgoverfreq is good or bad?
Message-ID: <SAT.20.NOV.2010.012036.0600.FIELDTRIP@NIC.SURFNET.NL>

Dear all,

I have spatio-spectral EEG data (no temporal information) from two
groups. Group A was tested three times (t1,t2,t3) during a treatment
and group B (control group) was also tested at the same three time
points. Now I simply want to know which <channel, frequency> pairs
differ for each group separately. Thus, I ran depsamplesF test
(cluster with montecarlo) for each group for a large frequency range,
say 0.5 - 100Hz, cfg.avgoverfreq = 'no'.  I then used Bonferroni
correction (for two tests) and plotted the clusters using multiplotTFR
with 'mask' as zstat parameter. The clusters of <ch, freq> I get are
mostly in 15-40Hz range and usually there is only one big cluster.

Now my question is - by running over a huge range of frequency (using
no averaging over freq), did I lower the power for low freq bands
(like delta, theta, and alpha)? Should I rather run these tests
separately for low freq bands (like delta, theta, and alpha) with
avgoverfreq='yes'. And may be another test for high frequencies like
14-100 Hz with no averaging over frequencies.

The reason I was running one test for all frequencies was to avoid
multiple tests and hence avoiding more stringent Bonferroni
correction.

Thanks,
m-



Manish Saggar,
Doctoral Candidate,
Department of Computer Science,
The University of Texas at Austin,
Web: http://www.cs.utexas.edu/~mishu/
Email: mishu at cs.utexas.edu

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From e.maris at DONDERS.RU.NL  Sat Nov 20 13:41:20 2010
From: e.maris at DONDERS.RU.NL (Eric Maris)
Date: Sat, 20 Nov 2010 13:41:20 +0100
Subject: avgoverfreq is good or bad?
In-Reply-To: <AANLkTinT9Jh+8PWVeX6a38vq6Qb=GR+Co9Lf7pj3i4TB@mail.gmail.com>
Message-ID: <SAT.20.NOV.2010.134120.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Manish,


As a rule, whenever you incorporate valid prior information in your
statistical analysis, you will increase sensitivity. For instance, assume
that there physiological reasons why effects should always occur in a number
of discrete frequency bands; [0.5,1.5] (delta), [4,6] (theta), [8,12]
(alpha), [13,30] (beta), and [31,80] (gamma). Then, you will increase power
by (1) estimating the average power in these frequency bands (using
multitaper estimation with the appropriate spectral smoothing), and (2)
performing a cluster-based permutation test on the resulting
(channel,frequency bin)-data. Without frequency smoothing in the a priori
defined frequency intervals sensitivity will be lower, assumed the intervals
are valid of course. You can further increase sensitivity if you know a
priori that effects will only occur in one of the frequency bands, but that
does not seem to be the case for you.

Good luck,

Eric Maris


dr. Eric Maris
Donders Institute for Brain, Cognition and Behavior
Center for Cognition and F.C. Donders Center for Cognitive Neuroimaging
Radboud University
P.O. Box 9104
6500 HE Nijmegen
The Netherlands
T:+31 24 3612651
Mobile: 06 39584581
F:+31 24 3616066
E: e.maris at donders.ru.nl







> -----Original Message-----
> From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On
> Behalf Of Manish Saggar
> Sent: zaterdag 20 november 2010 8:21
> To: FIELDTRIP at NIC.SURFNET.NL
> Subject: [FIELDTRIP] avgoverfreq is good or bad?
>
> Dear all,
>
> I have spatio-spectral EEG data (no temporal information) from two
> groups. Group A was tested three times (t1,t2,t3) during a treatment
> and group B (control group) was also tested at the same three time
> points. Now I simply want to know which <channel, frequency> pairs
> differ for each group separately. Thus, I ran depsamplesF test
> (cluster with montecarlo) for each group for a large frequency range,
> say 0.5 - 100Hz, cfg.avgoverfreq = 'no'.  I then used Bonferroni
> correction (for two tests) and plotted the clusters using multiplotTFR
> with 'mask' as zstat parameter. The clusters of <ch, freq> I get are
> mostly in 15-40Hz range and usually there is only one big cluster.
>
> Now my question is - by running over a huge range of frequency (using
> no averaging over freq), did I lower the power for low freq bands
> (like delta, theta, and alpha)? Should I rather run these tests
> separately for low freq bands (like delta, theta, and alpha) with
> avgoverfreq='yes'. And may be another test for high frequencies like
> 14-100 Hz with no averaging over frequencies.
>
> The reason I was running one test for all frequencies was to avoid
> multiple tests and hence avoiding more stringent Bonferroni
> correction.
>
> Thanks,
> m-
>
>
>
> Manish Saggar,
> Doctoral Candidate,
> Department of Computer Science,
> The University of Texas at Austin,
> Web: http://www.cs.utexas.edu/~mishu/
> Email: mishu at cs.utexas.edu
>
> -----------------------------------------------------------------------
> ----
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> -----------------------------------------------------------------------
> ----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From paul_c at GMX.DE  Mon Nov 22 07:28:21 2010
From: paul_c at GMX.DE (Paul Czienskowski)
Date: Mon, 22 Nov 2010 07:28:21 +0100
Subject: Stability of ft_dipolefitting
Message-ID: <MON.22.NOV.2010.072821.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear all,

as a pretest for my diploma thesis, which deals with the source
localization in EEG, I tried to generate some simulated EEG Data and fit
them both with the BEM model I generated them with and a BEM model I
generated from the icbm152 brain. The set of electrodes was generated
from the  10-20-system's instruction. I found that the  'real' brain
model fitted the data quite good, but the fitting with the other model
failed completely for it 'found' the dipole position on the way other
hemisphere pointing inwards instead of in the vertex direction. Since
this seemed quite  strange to us we decided to fit the data with one of
our other real brain models. Even if the dipole was located in the right
hemisphere now the fit was quite poor for it located the dipole in the
brain stem or in the medulla oblongata rather than in the auditory
cortex where it was simulated. When I didn't let the fit perform the
scan on the grid but let it run on some initial position in the auditory
cortex the fit with one of the other models performed a bit better but
still with a too small moment and still ~5 cm away from our position.
I know I won't be able to perform a perfect fit with another model but
it should be better than this - at least I thought - for I think we'll
never have a perfect model of a head and thus we wouldn't be able to
perform any reasonable fit if it was that unstable. Has anyone any clue
which could have been my fault. I know it's not easy without the data
and even the figures but maybe there's anything you already see from my
approach which was completely wrong. Some basic data: As I told you
before I used a 10-20-electrode-system, my models had 4 layers with each
about  1000 vertices ([999,1004] to be accurate), generated from a spm8
segmentation with a script inspired by
http://fieldtrip.fcdonders.nl/example/create_bem_headmodel_for_eeg . I
generated the models with OpenMEEG. For the grid search I used the gray
matter from the spm8 segmentation and down sampled it to a 5 mm grid.

Thanks in advance,
Paul Czienskowski

--
Paul Czienskowski
Max Planck institute for human development
Lentzeallee 94
14195 Berlin

Björnsonstr. 25
12163 Berlin

Tel.: (+49)(0)30/221609359
Handy: (+49)(0)1788378772

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From ekanal at CMU.EDU  Mon Nov 22 17:48:52 2010
From: ekanal at CMU.EDU (Kanal Eliezer)
Date: Mon, 22 Nov 2010 11:48:52 -0500
Subject: ft_rejectvisual: different scales for magnet- and gradi-ometers?
Message-ID: <MON.22.NOV.2010.114852.0500.FIELDTRIP@NIC.SURFNET.NL>

Hello folks -

In using ft_rejectvisual, it seems that the magnetometer and gradiometer data is on a different scale. See this picture [1] for an example of this. The help for ft_rejectvisual suggests that I can scale the meg data differently than the eeg data, but doesn't list any way to scale different types of MEG data. Is there any way I can scale data based using a user function? For example, all channels ending with '1' are meg, '2' and '3' are grad, so I can use that. Also, I know I can view the data independently using the cfg.channel config option... I want to know if I can have it on a single screen. Thanks!

Elli Kanal

[1] http://www.andrew.cmu.edu/user/ekanal/ft_rejectvisual-mag-vs-grad.png


--------------------
Eliezer Kanal, Ph.D.
Postdoctoral Fellow
Center for the Neural Basis of Cognition
Carnegie Mellon University
4400 Fifth Ave, Suite 115
Pittsburgh PA 15213
P: 412-268-4115
F: 412-268-5060

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From michael.wibral at WEB.DE  Mon Nov 22 19:54:44 2010
From: michael.wibral at WEB.DE (Michael Wibral)
Date: Mon, 22 Nov 2010 19:54:44 +0100
Subject: Combining different MEG sensortypes
Message-ID: <MON.22.NOV.2010.195444.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Fieldtrip users (with a Neuromag system),

I have a question on how to combine the Information from the planar gradiometers and the magnetometers of a 306 channel Neurmag system best for beamformer weight computation and source time course reconstruction. Do you compute a complete leadfield mixing both types of gradiometers (i.e. you do an unweighted analysis)? Do you somehow weight the sensors for their different noise levels? Do you compute two sets of timecourses (one from grads, one from megnetometers)?
A related question: Do you update the leadfileds for projections that MAxfiltering does (like it should be done when using ICA)?

I am asking because it has been shown that the more sensors are available the better the time course reconstruction (a recent paper by Matthew Brookes). Hence it would be a pity to have to throw some of the information away.

Michael

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Michael Wibral.vcf
Type: text/x-vcard
Size: 628 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101122/db9a9cd3/attachment.vcf>

From lauri at NEURO.HUT.FI  Tue Nov 23 08:24:52 2010
From: lauri at NEURO.HUT.FI (Lauri Parkkonen)
Date: Tue, 23 Nov 2010 09:24:52 +0200
Subject: Combining different MEG sensortypes
In-Reply-To: <893393094.122969.1290452084874.JavaMail.fmail@mwmweb053>
Message-ID: <TUE.23.NOV.2010.092452.0200.FIELDTRIP@NIC.SURFNET.NL>

Hello Michael,

At least for MNE and beamforming, the most common approach is to use
both magnetometers and planar gradiometers together in a single (mixed)
forward solution; however, weighting must be applied because the units
and numerical scales of the two sensor types are different. This
weighting is typically done by estimating the noise covariance matrix
and then using the reciprocals of the diagonal elements for each
channel. If obtaining the full noise covariance matrix is too
troublesome for some reason, the obvious shortcut is to just compute the
baseline noise RMS, i.e., the diagonal of the matrix, which is what the
multi-dipole modelling software (by Neuromag) does.

There is no localization or amplitude bias if you source model
SSS'ed/MaxFiltered data directly whereas -- as you pointed out -- such
bias does exist for ICA or otherwise projected data. The important
difference is that SSS includes complete models for all possible signal
patterns originating from the volumes inside and outside the sensor
array, and these subspaces are linearly independent. On the contrary, a
component/signal vector determined from the data (by ICA or PCA, for
example) generally has a non-vanishing projection on the brain signal
subspace and without knowing that subspace, there is no way to "undo"
the distortion of that part of the signal but one has to carry the
information about the projection all the way to the lead field.

You certainly know the following but for those who may wonder: After
MaxFiltering, one may still need to take into account the reduced number
of degrees of freedom in the regularisation in MNE and beamforming. For
example, dropping the lower N of the eigenvalues may not have the
desired effect as some of the retained eigenvalues may already be zero
in MaxFiltered data (while they would be small but non-zero for
non-filtered data).

Best regards,
Lauri

22.11.2010 20:54, Michael Wibral kirjoitti:
> Dear Fieldtrip users (with a Neuromag system),
>
> I have a question on how to combine the Information from the planar gradiometers and the magnetometers of a 306 channel Neurmag system best for beamformer weight computation and source time course reconstruction. Do you compute a complete leadfield mixing both types of gradiometers (i.e. you do an unweighted analysis)? Do you somehow weight the sensors for their different noise levels? Do you compute two sets of timecourses (one from grads, one from megnetometers)?
> A related question: Do you update the leadfileds for projections that MAxfiltering does (like it should be done when using ICA)?
>
> I am asking because it has been shown that the more sensors are available the better the time course reconstruction (a recent paper by Matthew Brookes). Hence it would be a pity to have to throw some of the information away.
>
> Michael
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE  Tue Nov 23 10:20:22 2010
From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann)
Date: Tue, 23 Nov 2010 10:20:22 +0100
Subject: paths to connectivity function
Message-ID: <TUE.23.NOV.2010.102022.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear fieldtrip developers,

 

I have just installed the newest version as outlined on your website
(addpath without genpath and calling fieldtripdefs, old paths removed).
I noticed that calling ft_connectivityanalysis with method "coh" now
results in the error

 

??? Undefined function or method 'univariate2bivariate' for input
arguments of type 'struct'.

 

It is overcome by manually adding the folder connectivity to the search
path. Maybe fieldtripdefs does not include the connectivity functions
correctly?

 

Best,

jan

 

Jan Hirschmann

MSc. Neuroscience

Insititute of Clinical Neuroscience and Medical Psychology

Heinrich Heine University Duesseldorf

Universitaetsstr.  1
40225  Duesseldorf

Tel: 0049 - (0)211 - 81 - 18076

 


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/5b9770aa/attachment.htm>

From jan.schoffelen at DONDERS.RU.NL  Tue Nov 23 10:30:01 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Tue, 23 Nov 2010 10:30:01 +0100
Subject: paths to connectivity function
In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8B01DC8D02@Mail2-UKD.VMED.UKD>
Message-ID: <TUE.23.NOV.2010.103001.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Jan,

Thanks for letting us know. As far as I can see, the function  
fieldtripdefs tries to add the connectivity folder to the path (line  
112 of version 2017). Are you sure you are using the most recent  
fieldtripdefs function?

Best,

JM

On Nov 23, 2010, at 10:20 AM, Jan Hirschmann wrote:


> Dear fieldtrip developers,
>
> I have just installed the newest version as outlined on your website  
> (addpath without genpath and calling fieldtripdefs, old paths  
> removed). I noticed that calling ft_connectivityanalysis with method  
> “coh” now results in the error
>
> ??? Undefined function or method 'univariate2bivariate' for input  
> arguments of type ‘struct'.
>
> It is overcome by manually adding the folder connectivity to the  
> search path. Maybe fieldtripdefs does not include the connectivity  
> functions correctly?
>
> Best,
> jan
>
> Jan Hirschmann
> MSc. Neuroscience
> Insititute of Clinical Neuroscience and Medical Psychology
> Heinrich Heine University Duesseldorf
> Universitaetsstr.  1
> 40225  Duesseldorf
> Tel: 0049 - (0)211 - 81 - 18076
>
> --------------------------------------------------------------------------- You 
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the  
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/354d814d/attachment.htm>

From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE  Tue Nov 23 10:34:17 2010
From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann)
Date: Tue, 23 Nov 2010 10:34:17 +0100
Subject: poor guys called Jan
Message-ID: <TUE.23.NOV.2010.103417.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi,

 

as I am on it, I might as well make another minor improvement
suggestion. Ft_freqstatistics asks the system whether the user is named
jan and if so, calls statistics_wrapperJM instead of statistics_wrapper.
For people named Jan this is inconvenient, as the JM function is
probably found nowhere but on Jan-Mathijs' computer, I guess. What about
all the other Jans? :-)

 

Best,

jan


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/6a17280e/attachment.htm>

From michael.wibral at WEB.DE  Tue Nov 23 10:37:10 2010
From: michael.wibral at WEB.DE (Michael Wibral)
Date: Tue, 23 Nov 2010 10:37:10 +0100
Subject: Combining different MEG sensortypes
In-Reply-To: <4CEB6C44.6070109@neuro.hut.fi>
Message-ID: <TUE.23.NOV.2010.103710.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Lauri,

thank you very much for your reply that was indeed very helpful.

Michael

-----Ursprüngliche Nachricht-----
Von: "Lauri Parkkonen" <lauri at NEURO.HUT.FI>
Gesendet: Nov 23, 2010 8:24:52 AM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] Combining different MEG sensortypes

>Hello Michael,
>
>At least for MNE and beamforming, the most common approach is to use 
>both magnetometers and planar gradiometers together in a single (mixed) 
>forward solution; however, weighting must be applied because the units 
>and numerical scales of the two sensor types are different. This 
>weighting is typically done by estimating the noise covariance matrix 
>and then using the reciprocals of the diagonal elements for each 
>channel. If obtaining the full noise covariance matrix is too 
>troublesome for some reason, the obvious shortcut is to just compute the 
>baseline noise RMS, i.e., the diagonal of the matrix, which is what the 
>multi-dipole modelling software (by Neuromag) does.
>
>There is no localization or amplitude bias if you source model 
>SSS'ed/MaxFiltered data directly whereas -- as you pointed out -- such 
>bias does exist for ICA or otherwise projected data. The important 
>difference is that SSS includes complete models for all possible signal 
>patterns originating from the volumes inside and outside the sensor 
>array, and these subspaces are linearly independent. On the contrary, a 
>component/signal vector determined from the data (by ICA or PCA, for 
>example) generally has a non-vanishing projection on the brain signal 
>subspace and without knowing that subspace, there is no way to "undo" 
>the distortion of that part of the signal but one has to carry the 
>information about the projection all the way to the lead field.
>
>You certainly know the following but for those who may wonder: After 
>MaxFiltering, one may still need to take into account the reduced number 
>of degrees of freedom in the regularisation in MNE and beamforming. For 
>example, dropping the lower N of the eigenvalues may not have the 
>desired effect as some of the retained eigenvalues may already be zero 
>in MaxFiltered data (while they would be small but non-zero for 
>non-filtered data).
>
>Best regards,
>Lauri
>
>22.11.2010 20:54, Michael Wibral kirjoitti:
>> Dear Fieldtrip users (with a Neuromag system),
>>
>> I have a question on how to combine the Information from the planar gradiometers and the magnetometers of a 306 channel Neurmag system best for beamformer weight computation and source time course reconstruction. Do you compute a complete leadfield mixing both types of gradiometers (i.e. you do an unweighted analysis)? Do you somehow weight the sensors for their different noise levels? Do you compute two sets of timecourses (one from grads, one from megnetometers)?
>> A related question: Do you update the leadfileds for projections that MAxfiltering does (like it should be done when using ICA)?
>>
>> I am asking because it has been shown that the more sensors are available the better the time course reconstruction (a recent paper by Matthew Brookes). Hence it would be a pity to have to throw some of the information away.
>>
>> Michael
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>
>---------------------------------------------------------------------------
>You are receiving this message because you are subscribed to
>the  FieldTrip list. The aim of this list is to facilitate the discussion
>between  users of the FieldTrip  toolbox, to share experiences
>and to discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Michael Wibral.vcf
Type: text/x-vcard
Size: 628 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/d4ac749d/attachment.vcf>

From jan.schoffelen at DONDERS.RU.NL  Tue Nov 23 10:40:41 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Tue, 23 Nov 2010 10:40:41 +0100
Subject: poor guys called Jan
In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8B01DC8D12@Mail2-UKD.VMED.UKD>
Message-ID: <TUE.23.NOV.2010.104041.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Jan,

Oops. Yes, I sincerely apologize for this one. I thought I took it out  
already a while ago. I'll do it as we speak. Or would you prefer to  
have the statistics_wrapperJM? Then we can start our own little  
fieldtrip-twig ;o).

Cheers,

Jan-M


On Nov 23, 2010, at 10:34 AM, Jan Hirschmann wrote:

> Hi,
>
> as I am on it, I might as well make another minor improvement  
> suggestion. Ft_freqstatistics asks the system whether the user is  
> named jan and if so, calls statistics_wrapperJM instead of  
> statistics_wrapper. For people named Jan this is inconvenient, as  
> the JM function is probably found nowhere but on Jan-Mathijs’  
> computer, I guess. What about all the other Jans? J
>
> Best,
> jan
> --------------------------------------------------------------------------- You 
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the  
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/2976cb85/attachment.htm>

From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE  Tue Nov 23 10:45:58 2010
From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann)
Date: Tue, 23 Nov 2010 10:45:58 +0100
Subject: AW: [FIELDTRIP] paths to connectivity function
In-Reply-To: A<50C33905-E76F-4927-AC34-9241B4B54FB3@donders.ru.nl>
Message-ID: <TUE.23.NOV.2010.104558.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Jan-Mathijs,

 

I think I am. According to Matlabs which function at least, and the code
you are relating to is at line 112 in my function, too.

 

Best,

jan

 

________________________________

Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im
Auftrag von jan-mathijs schoffelen
Gesendet: Dienstag, 23. November 2010 10:30
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] paths to connectivity function

 

Dear Jan,

 

Thanks for letting us know. As far as I can see, the function
fieldtripdefs tries to add the connectivity folder to the path (line 112
of version 2017). Are you sure you are using the most recent
fieldtripdefs function?

 

Best,

 

JM

 

On Nov 23, 2010, at 10:20 AM, Jan Hirschmann wrote:

 





Dear fieldtrip developers,

 

I have just installed the newest version as outlined on your website
(addpath without genpath and calling fieldtripdefs, old paths removed).
I noticed that calling ft_connectivityanalysis with method "coh" now
results in the error

 

??? Undefined function or method 'univariate2bivariate' for input
arguments of type 'struct'.

 

It is overcome by manually adding the folder connectivity to the search
path. Maybe fieldtripdefs does not include the connectivity functions
correctly?

 

Best,

jan

 

Jan Hirschmann

MSc. Neuroscience

Insititute of Clinical Neuroscience and Medical Psychology

Heinrich Heine University Duesseldorf

Universitaetsstr.  1
40225  Duesseldorf

Tel: 0049 - (0)211 - 81 - 18076

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---

 

Dr. J.M. (Jan-Mathijs) Schoffelen 

Donders Institute for Brain, Cognition and Behaviour, 
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands

J.Schoffelen at donders.ru.nl

Telephone: 0031-24-3614793

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/8755064e/attachment.htm>

From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE  Tue Nov 23 11:05:52 2010
From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann)
Date: Tue, 23 Nov 2010 11:05:52 +0100
Subject: AW: [FIELDTRIP] poor guys called Jan
In-Reply-To: A<A700BB31-4C06-42BF-A4C4-B10FA56C8694@donders.ru.nl>
Message-ID: <TUE.23.NOV.2010.110552.0100.FIELDTRIP@NIC.SURFNET.NL>

No prob. Yes, I think the Jan-files must be the ones with all the fancy
new techniques the world is yet to marvel about. And some exclusive
clubs would somehow spice up the open source life a bit, won't they? But
to keep personal confusion at acceptable levels I prefer struggling with
the nice, meant-to-be-read code of the official package first.

 

Best,

jan

 

________________________________

Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im
Auftrag von jan-mathijs schoffelen
Gesendet: Dienstag, 23. November 2010 10:41
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] poor guys called Jan

 

Dear Jan,

 

Oops. Yes, I sincerely apologize for this one. I thought I took it out
already a while ago. I'll do it as we speak. Or would you prefer to have
the statistics_wrapperJM? Then we can start our own little
fieldtrip-twig ;o).

 

Cheers,

 

Jan-M

 

 

On Nov 23, 2010, at 10:34 AM, Jan Hirschmann wrote:





Hi,

 

as I am on it, I might as well make another minor improvement
suggestion. Ft_freqstatistics asks the system whether the user is named
jan and if so, calls statistics_wrapperJM instead of statistics_wrapper.
For people named Jan this is inconvenient, as the JM function is
probably found nowhere but on Jan-Mathijs' computer, I guess. What about
all the other Jans? :-)

 

Best,

jan

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---

 

Dr. J.M. (Jan-Mathijs) Schoffelen 

Donders Institute for Brain, Cognition and Behaviour, 
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands

J.Schoffelen at donders.ru.nl

Telephone: 0031-24-3614793

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/5a2f79ca/attachment.htm>

From jan.schoffelen at DONDERS.RU.NL  Tue Nov 23 11:21:28 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Tue, 23 Nov 2010 11:21:28 +0100
Subject: AW: [FIELDTRIP] paths to connectivity function
In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8B01DC8D1A@Mail2-UKD.VMED.UKD>
Message-ID: <TUE.23.NOV.2010.112128.0100.FIELDTRIP@NIC.SURFNET.NL>

It seems as if ft_hastoolbox fails there (and does so unnoticed due to  
the try and catch statements). Could you check what happens if you  
comment out the try and catch?

Thanks,

JM

PS: for me it still works


On Nov 23, 2010, at 10:45 AM, Jan Hirschmann wrote:

> Dear Jan-Mathijs,
>
> I think I am. According to Matlabs which function at least, and the  
> code you are relating to is at line 112 in my function, too.
>
> Best,
> jan
>
> Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im  
> Auftrag von jan-mathijs schoffelen
> Gesendet: Dienstag, 23. November 2010 10:30
> An: FIELDTRIP at NIC.SURFNET.NL
> Betreff: Re: [FIELDTRIP] paths to connectivity function
>
> Dear Jan,
>
> Thanks for letting us know. As far as I can see, the function  
> fieldtripdefs tries to add the connectivity folder to the path (line  
> 112 of version 2017). Are you sure you are using the most recent  
> fieldtripdefs function?
>
> Best,
>
> JM
>
> On Nov 23, 2010, at 10:20 AM, Jan Hirschmann wrote:
>
>
>
> Dear fieldtrip developers,
>
> I have just installed the newest version as outlined on your website  
> (addpath without genpath and calling fieldtripdefs, old paths  
> removed). I noticed that calling ft_connectivityanalysis with method  
> “coh” now results in the error
>
> ??? Undefined function or method 'univariate2bivariate' for input  
> arguments of type ‘struct'.
>
> It is overcome by manually adding the folder connectivity to the  
> search path. Maybe fieldtripdefs does not include the connectivity  
> functions correctly?
>
> Best,
> jan
>
> Jan Hirschmann
> MSc. Neuroscience
> Insititute of Clinical Neuroscience and Medical Psychology
> Heinrich Heine University Duesseldorf
> Universitaetsstr.  1
> 40225  Duesseldorf
> Tel: 0049 - (0)211 - 81 - 18076
>
> --------------------------------------------------------------------------- You 
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the  
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>
>
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl
> Telephone: 0031-24-3614793
>
> --------------------------------------------------------------------------- You 
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the  
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>
> --------------------------------------------------------------------------- You 
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the  
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/18e7e257/attachment.htm>

From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE  Tue Nov 23 13:44:07 2010
From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann)
Date: Tue, 23 Nov 2010 13:44:07 +0100
Subject: AW: [FIELDTRIP] AW: [FIELDTRIP] paths to connectivity function
In-Reply-To: A<8AB02C02-18BF-4E34-9BE9-00E20D18CF78@donders.ru.nl>
Message-ID: <TUE.23.NOV.2010.134407.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi,

 

the problem was that in my startup file I add spm8 to the search path
which has its own fieldtrip. I should have used rmpath(genpath(...)) to
remove this fieldtrip but I only used rmpath(...). So it was my mistake,
sorry. In this context I wonder about the function fieldtripdefs. For
example, when spm8 is not on the path, it checks for the package with
ft_hastoolbox(spm8). The function returns an error message telling the
user that spm8 is not installed. However, the error message is never
displayed because ft_hastoolbox comes after a try statement. 

 

Best,

jan

 

________________________________

Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im
Auftrag von jan-mathijs schoffelen
Gesendet: Dienstag, 23. November 2010 11:21
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] AW: [FIELDTRIP] paths to connectivity function

 

It seems as if ft_hastoolbox fails there (and does so unnoticed due to
the try and catch statements). Could you check what happens if you
comment out the try and catch?

 

Thanks,

 

JM

 

PS: for me it still works

 

 

On Nov 23, 2010, at 10:45 AM, Jan Hirschmann wrote:





Dear Jan-Mathijs,

 

I think I am. According to Matlabs which function at least, and the code
you are relating to is at line 112 in my function, too.

 

Best,

jan

 

________________________________

Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im
Auftrag von jan-mathijs schoffelen
Gesendet: Dienstag, 23. November 2010 10:30
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] paths to connectivity function

 

Dear Jan,

 

Thanks for letting us know. As far as I can see, the function
fieldtripdefs tries to add the connectivity folder to the path (line 112
of version 2017). Are you sure you are using the most recent
fieldtripdefs function?

 

Best,

 

JM

 

On Nov 23, 2010, at 10:20 AM, Jan Hirschmann wrote:

 






Dear fieldtrip developers,

 

I have just installed the newest version as outlined on your website
(addpath without genpath and calling fieldtripdefs, old paths removed).
I noticed that calling ft_connectivityanalysis with method "coh" now
results in the error

 

??? Undefined function or method 'univariate2bivariate' for input
arguments of type 'struct'.

 

It is overcome by manually adding the folder connectivity to the search
path. Maybe fieldtripdefs does not include the connectivity functions
correctly?

 

Best,

jan

 

Jan Hirschmann

MSc. Neuroscience

Insititute of Clinical Neuroscience and Medical Psychology

Heinrich Heine University Duesseldorf

Universitaetsstr.  1
40225  Duesseldorf

Tel: 0049 - (0)211 - 81 - 18076

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---

 

Dr. J.M. (Jan-Mathijs) Schoffelen 

Donders Institute for Brain, Cognition and Behaviour, 
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands

J.Schoffelen at donders.ru.nl

Telephone: 0031-24-3614793

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---

 

Dr. J.M. (Jan-Mathijs) Schoffelen 

Donders Institute for Brain, Cognition and Behaviour, 
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands

J.Schoffelen at donders.ru.nl

Telephone: 0031-24-3614793

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/d616f37e/attachment.htm>

From tolgacan1 at YAHOO.COM  Tue Nov 23 15:58:10 2010
From: tolgacan1 at YAHOO.COM (=?iso-8859-1?Q?Tolga_=D6zkurt?=)
Date: Tue, 23 Nov 2010 06:58:10 -0800
Subject: Combining different MEG sensortypes
In-Reply-To: <893393094.122969.1290452084874.JavaMail.fmail@mwmweb053>
Message-ID: <TUE.23.NOV.2010.065810.0800.FIELDTRIP@NIC.SURFNET.NL>

This had also been a question in my mind for a while.
Hey Michael,


This had also been a question in my mind for a while.

As you say so, magnetometers and gradiometers have different noise levels and 
obviously different units; I believe the magnetoemeters are wegihted by some 
value like "100" in Maxwell Filtering (for SSS decomposition) to avoid the 
singularity in the gain matrix. However, when I tried the same weigthing for 
beamforming algorithm in the Fieldtrip toolbox for a real data experiment, I 
could not get a good performance when I compared the localization results to the 
results obtained with "only gradiometers" or "only magnetometers". That is, 
weighting 100 was not optimal; although the results was much better than the 
lozalization result "with no weighting" at all. This means some optimal 
weighting required.

I suppose it makes sense to use the fabric noise levels of the sensors while 
weighting them. There is also a way suggested by by Henson et. al. (2009) that 
uses a Bayesian scheme to obtain optimal noise estimates, although I did not 
attempt to work into that approach yet. 


By the way, could you tell me the date and title of the "the recent paper by 
Matthew Brookes" you mentioned? It sounds like an interesting one.

Regards,

Tolga  






----- Original Message ----
From: Michael Wibral <michael.wibral at WEB.DE>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Mon, November 22, 2010 7:54:44 PM
Subject: [FIELDTRIP] Combining different MEG sensortypes

Dear Fieldtrip users (with a Neuromag system),

I have a question on how to combine the Information from the planar gradiometers 
and the magnetometers of a 306 channel Neurmag system best for beamformer weight 
computation and source time course reconstruction. Do you compute a complete 
leadfield mixing both types of gradiometers (i.e. you do an unweighted 
analysis)? Do you somehow weight the sensors for their different noise levels? 
Do you compute two sets of timecourses (one from grads, one from megnetometers)?
A related question: Do you update the leadfileds for projections that 
MAxfiltering does (like it should be done when using ICA)?

I am asking because it has been shown that the more sensors are available the 
better the time course reconstruction (a recent paper by Matthew Brookes). Hence 
it would be a pity to have to throw some of the information away.

Michael

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------




---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From Nina.Kahlbrock at UNI-DUESSELDORF.DE  Tue Nov 23 15:58:34 2010
From: Nina.Kahlbrock at UNI-DUESSELDORF.DE (Nina Kahlbrock)
Date: Tue, 23 Nov 2010 15:58:34 +0100
Subject: statistics and NaNs in single channels
Message-ID: <TUE.23.NOV.2010.155834.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi all, 

I have a question concerning statistics and missing values.

I have data of 32 subjects (divided into four groups). Between these
subjects different channels were rejected due to artifacts. I would like to
avoid interpolating those channels but continue with filling up bad channels
with NaNs (i.e. subject one has channels 1, 3, and 17 filled up with NaNs,
subject two has channels 1, 7, 19, and 33 filled up with NaNs etc.).

What I would like to look at is if there are differences between groups in
certain cortical areas (I would calculate tfrs, average over certain
channels and then run a group analysis).

Does this pose a statistical problem, as there are differing numbers of
channels contributing to the average between groups? If I do not average
over channels, would it be allowed to identify significantly different
cortical areas between groups on sensor level?

Thank you in advance for any help!

Nina

 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - -

 

Nina Kahlbrock

Institute of Clinical Neuroscience and Medical Psychology 

Heinrich Heine University Duesseldorf

Universitaetsstr.  1

40225  Düsseldorf

 

Tel.:      +49 211 81 18075

Fax. .:   +49 211 81 19916

 

Mail:      <mailto:Nina.Kahlbrock at med.uni-duesseldorf.de>
Nina.Kahlbrock at med.uni-duesseldorf.de

 <http://www.uniklinik-duesseldorf.de/medpsychologie>
http://www.uniklinik-duesseldorf.de/medpsychologie

 


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/e8a30ea1/attachment.htm>

From psowman at MACCS.MQ.EDU.AU  Mon Nov  1 04:28:23 2010
From: psowman at MACCS.MQ.EDU.AU (Paul Sowman)
Date: Mon, 1 Nov 2010 04:28:23 +0100
Subject: ft_megrealign
Message-ID: <MON.1.NOV.2010.042823.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi, I'd like to use ft_megrealign with our Yokagawa systems.

I get this error:

>> interp1 = ft_megrealign(cfg, data_meg)
the input is raw data with 128 channels and 1 trials
removing 128 non-MEG channels from the data
Warning: could be Yokogawa system
> In ft_senstype at 233
  In ft_megrealign at 186
??? Error using ==> ft_megrealign at 209
unsupported MEG system for realigning, please
ask on the mailing list

Is it a matter of relabeling channels?

Thanks, Paul

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From psowman at MACCS.MQ.EDU.AU  Mon Nov  1 05:19:07 2010
From: psowman at MACCS.MQ.EDU.AU (Paul Sowman)
Date: Mon, 1 Nov 2010 05:19:07 +0100
Subject: ft_megrealign
Message-ID: <MON.1.NOV.2010.051907.0100.FIELDTRIP@NIC.SURFNET.NL>

Further to my last message, we have a yokogawa 64 channel system that
doesn't seem to be supported under ft_senstype. The .con file setup is the
same and reads in ok but because the number of channels is smaller the
senstype fails. Is there a way I could work around this? 

Thanks again, Paul

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From psowman at MACCS.MQ.EDU.AU  Mon Nov  1 06:27:22 2010
From: psowman at MACCS.MQ.EDU.AU (Paul Sowman)
Date: Mon, 1 Nov 2010 06:27:22 +0100
Subject: ft_megrealign
Message-ID: <MON.1.NOV.2010.062722.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi I'd like to use ft_megrealign on my Yokogawa data however it seems that
this function doesn't currently have Yokogawa support.
I get:

>> interp1 = ft_megrealign(cfg, data_meg)
the input is raw data with 128 channels and 1 trials
removing 128 non-MEG channels from the data
Warning: could be Yokogawa system
> In ft_senstype at 233
  In ft_megrealign at 186
??? Error using ==> ft_megrealign at 209
unsupported MEG system for realigning, please
ask on the mailing list

Is there a way to work around this?

Thanks, Paul

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From lwn_07 at YAHOO.COM.CN  Mon Nov  1 16:36:17 2010
From: lwn_07 at YAHOO.COM.CN (=?utf-8?B?5p2O5Y2r5aic?=)
Date: Mon, 1 Nov 2010 23:36:17 +0800
Subject: About eeg rereference
Message-ID: <MON.1.NOV.2010.233617.0800.FIELDTRIP@NIC.SURFNET.NL>

Dear Jan and other fieldtripers,
I'm dealing with my EEG data. I want to run some cross correlation and coherence on them. The problem is:
1. which reference method will you advise me to choice? my data is reference to the vertex(Cz), i don't know whether it's ok, seems most of you choose the average between left and right mastoid.
2.IF we will do rereference,it's guided in  the m-file 'ft_preprocessing' that we might configure our inputs as
"%   cfg.reref         = 'no' or 'yes' (default = 'no')
%   cfg.refchannel    = cell-array with new EEG reference channel(s)
%   cfg.implicitref   = 'label' or empty, add the implicit EEG reference as zeros (default = [])
%   cfg.montage       = 'no' or a montage structure (default = 'no')"
then, what's the difference between "reref" and "montage"?
      Is the montage structure a matrix, and how it defines?If I modify my data to an average rereference, how will be the input configured?

Best,
Weina LI




---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101101/edeb6292/attachment-0001.htm>

From xiaohanh at ANDREW.CMU.EDU  Mon Nov  1 18:27:22 2010
From: xiaohanh at ANDREW.CMU.EDU (Xiaohan Huang)
Date: Mon, 1 Nov 2010 13:27:22 -0400
Subject: Questions about creating template. Thank you.
Message-ID: <MON.1.NOV.2010.132722.0400.FIELDTRIP@NIC.SURFNET.NL>

Dear fieldtrip developers,

Hi. I am interested in fieldtrip. I think it is very useful.

I am now studying the example of
"read_neuromag_mri_and_create_single-subject_grids_in_individual_head_space_that_are_all_aligned_in_mni_space"
(http://fieldtrip.fcdonders.nl/example/read_neuromag_mri_and_create_single-subject_grids_in_individual_head_space_that_are_all_aligned_in_mni_space).
I notice that there is one step to set the cfg.template. I am a little
confused about this. Would you please tell me what is the usage of
template? And do we have to set template before we process the neuromag
fif data? And should this template be different from the one for .mri
file, as used in http://fieldtrip.fcdonders.nl/tutorial/beamformer?

Thank you so much,
Xiaohan

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From e.vandenbroeke at ANES.UMCN.NL  Tue Nov  2 22:23:22 2010
From: e.vandenbroeke at ANES.UMCN.NL (Emanuel van den Broeke)
Date: Tue, 2 Nov 2010 22:23:22 +0100
Subject: cluster based analysis
Message-ID: <TUE.2.NOV.2010.222322.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear dr. Maris,

Allow me to ask you one more question about the cluster-based analysis.
I have three groups but I'm only interested in two combinations:
group A versus B and 
group B versus C

Is it allowed to do two single cluster-based analyses with the above 
mentioned pairs and with a Bonferroni correction of the p-value for the two 
comparisons or is it required to run a single three-group analysis using the 
indepsamplesF statistic?

I know I already asked you this question earlier but a bit different, but I'm still 
insecure about this. You answered my previous question with:
alternatively, you may run a single three-group analyis...
But are two single cluster-based analyses also allowed in this case in your 
opinion?

Many thanks in advance,
Best emanuel

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From e.maris at DONDERS.RU.NL  Tue Nov  2 22:32:22 2010
From: e.maris at DONDERS.RU.NL (Eric Maris)
Date: Tue, 2 Nov 2010 22:32:22 +0100
Subject: cluster based analysis
In-Reply-To: <LISTSERV%201011022223222720.1CB0@NIC.SURFNET.NL>
Message-ID: <TUE.2.NOV.2010.223222.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Emanuel,

> Is it allowed to do two single cluster-based analyses with the above
> mentioned pairs and with a Bonferroni correction of the p-value for the
> two
> comparisons or is it required to run a single three-group analysis
> using the
> indepsamplesF statistic?

Two cluster-based analyses plus Bonferroni correction is allowed.

Good luck,

Eric


>
> I know I already asked you this question earlier but a bit different,
> but I'm still
> insecure about this. You answered my previous question with:
> alternatively, you may run a single three-group analyis...
> But are two single cluster-based analyses also allowed in this case in
> your
> opinion?
>
> Many thanks in advance,
> Best emanuel
>
> -----------------------------------------------------------------------
> ----
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> -----------------------------------------------------------------------
> ----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From karl.doron at GMAIL.COM  Wed Nov  3 00:08:51 2010
From: karl.doron at GMAIL.COM (Karl Doron)
Date: Wed, 3 Nov 2010 00:08:51 +0100
Subject: Return index of rejected trials
Message-ID: <WED.3.NOV.2010.000851.0100.FIELDTRIP@NIC.SURFNET.NL>

Hello,

Is it possible to have ft_artifact_eog (or artifact_zvalue) return the index of any 
rejected trials? I'm looking for it in terms of the index of the input data. 

For example, if my trial definition function creates 100 trials and artifact_eog 
(and zvalue) find that trials 8, 15 and 38 should be rejected, can I output a 
vector=[8 15 38]?

cfg.trl and cfg.trlold give the beginning and end of each rejected trial in terms of 
experiment time.

Thanks for any help.

Karl Doron
PhD candidate
UC, Santa Barbara

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From karl.doron at GMAIL.COM  Wed Nov  3 00:29:29 2010
From: karl.doron at GMAIL.COM (Karl Doron)
Date: Wed, 3 Nov 2010 00:29:29 +0100
Subject: Return index of rejected trials
Message-ID: <WED.3.NOV.2010.002929.0100.FIELDTRIP@NIC.SURFNET.NL>

I answered my own question!

new=data.cfg.trl(:,1);
old=data.cfg.trlold(:,1);

[TF, ~]=ismember(old, new);
for i=1:length(TF)
   if TF(i)==0
      rej(i)=i;
  end
end

rejected=nonzeros(rej);

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From maarten.de.vos at UNI-OLDENBURG.DE  Wed Nov  3 10:09:05 2010
From: maarten.de.vos at UNI-OLDENBURG.DE (Maarten De Vos)
Date: Wed, 3 Nov 2010 10:09:05 +0100
Subject: Remove muscle artifacts using ICA
In-Reply-To: <05CCB530-2AD1-42CF-B6B4-9898D5224008@donders.ru.nl>
Message-ID: <WED.3.NOV.2010.100905.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Marc,

sometimes ICA is suboptimal for muscle artifacts.  Not always, depends
indeed how your data look like.

for an alternative method, please see

De Clercq W., Vergult A., Vanrumste B., Van Paesschen W., Van Huffel S.,
"Canonical Correlation Analysis Applied to Remove Muscle Artifacts From
the Electroencephalogram", IEEE Transactions on Biomedical Engineering,
Vol.  53, No. 12, December 2006, pp. 2583-2587.

and De Vos M, Riès S, Vanderperren K, Vanrumste B, Alario FX, Van Huffel
S, Burle B.
Neuroinformatics. 2010 Jun;8(2):135-50.
Removal of muscle artifacts from EEG recordings of spoken language
production.


Hope this helps,
maarten

jan-mathijs schoffelen wrote:
> Dear Marc,
>
> Your figures seem to be missing, so it is hard to judge what the
> artifacts look like exactly. Could it be that one of your head
> localization coils was switched on througout the measurement?
> In general, if your goal is to do source localization, I would not try
> to fix ugly channels, but just omit them from the sensor-array,
> because there will be plenty of sensors left.
> The fixing operation (whatever way it is done, e.g. nearest neighbour
> interpolation, ICA etc) involves replacing each channel's estimate by
> a linear combination of a subset of/all other channels. You have to
> keep in mind that the solution to the forward model (i.e. the
> leadfields for the sources you want to estimate) have to take the same
> linear operation into account in order to give correct results.
> As such, irrespective of the fact that the noisy channels are on the
> edge of the array, interpolation does not really make sense, because
> you are not really improving the quality of your total signal array.
> Also, in this case, I don't expect that rejecting the independent
> component capturing the artifact will be that beneficial, because most
> likely the spatial topography of this component of this component will
> be confined to the three bad guys, with more or less random loadings
> on the rest of the channels. Did you check whether the artifact is
> present at the level of the reference sensors? If that's the case, you
> could consider applying the cfw and afw (compute fixed weights, and
> apply fixed weights) utilities from the 4D software.
>
> Best wishes
>
> Jan-Mathijs
>
>
> On Oct 28, 2010, at 7:11 PM, Marc Recasens wrote:
>
>> Dear all,
>>
>> I have quite a naive question.
>> I'm processing some MEG (4-D) datasets in order to use source
>> location methods afterwards. One of my concerns is that I have some
>> channels (3 in a row) with a steady high frequency artifact >50Hz (I
>> thought it is muscle activity, However it is very tonic and present
>> during the whole recording) which is within my frequencies of
>> interest. This can be seen in the attached figures: timelocked
>> responses bandpass filtered between 15 and 150 Hz, and time-frequency
>> activity between 50 and 100 Hz.
>> As the artefactual channels are put altogether in the right edge of
>> the sensor array (A148, A147 and A146) interpolation may not be a
>> suitable method to eliminate those artefactual channels. (?)
>>
>> I was wondering whether it is possible to correct those artifacts
>> using ICA in such a way similar to ECG artifact removal using
>> component analysis, that is, by identifying  and remove those
>> components in the source analysis that explain the high-frequency
>> artifacts present in some of my channels.
>>
>> Thanks a lot.
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> --
>> Marc Recasens
>> Tel.: +34 639 24 15 98
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the FieldTrip list. The aim of this list is to facilitate the discussion
>> between users of the FieldTrip toolbox, to share experiences
>> and to discuss new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>>
>
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl <mailto:J.Schoffelen at donders.ru.nl>
> Telephone: 0031-24-3614793
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From shackman at WISC.EDU  Wed Nov  3 14:42:08 2010
From: shackman at WISC.EDU (Alexander J. Shackman)
Date: Wed, 3 Nov 2010 08:42:08 -0500
Subject: Remove muscle artifacts using ICA
In-Reply-To: <4CD126B1.9030106@uni-oldenburg.de>
Message-ID: <WED.3.NOV.2010.084208.0500.>

re: ica

you might also take a look at,

http://psyphz.psych.wisc.edu/%7Eshackman/mcmenamin_shackman_davidson_ni2010.pdf

in particular, the supplement appended to the end.

good luck,
alex

On Wed, Nov 3, 2010 at 4:09 AM, Maarten De Vos <
maarten.de.vos at uni-oldenburg.de> wrote:

> Dear Marc,
>
> sometimes ICA is suboptimal for muscle artifacts.  Not always, depends
> indeed how your data look like.
>
> for an alternative method, please see
>
> De Clercq W., Vergult A., Vanrumste B., Van Paesschen W., Van Huffel S.,
> "Canonical Correlation Analysis Applied to Remove Muscle Artifacts From the
> Electroencephalogram", IEEE Transactions on Biomedical Engineering, Vol.
>  53, No. 12, December 2006, pp. 2583-2587.
>
> and De Vos M, Riès S, Vanderperren K, Vanrumste B, Alario FX, Van Huffel S,
> Burle B.
> Neuroinformatics. 2010 Jun;8(2):135-50.
> Removal of muscle artifacts from EEG recordings of spoken language
> production.
>
>
> Hope this helps,
> maarten
>
> jan-mathijs schoffelen wrote:
>
>> Dear Marc,
>>
>> Your figures seem to be missing, so it is hard to judge what the artifacts
>> look like exactly. Could it be that one of your head localization coils was
>> switched on througout the measurement?
>> In general, if your goal is to do source localization, I would not try to
>> fix ugly channels, but just omit them from the sensor-array, because there
>> will be plenty of sensors left.
>> The fixing operation (whatever way it is done, e.g. nearest neighbour
>> interpolation, ICA etc) involves replacing each channel's estimate by a
>> linear combination of a subset of/all other channels. You have to keep in
>> mind that the solution to the forward model (i.e. the leadfields for the
>> sources you want to estimate) have to take the same linear operation into
>> account in order to give correct results. As such, irrespective of the fact
>> that the noisy channels are on the edge of the array, interpolation does not
>> really make sense, because you are not really improving the quality of your
>> total signal array. Also, in this case, I don't expect that rejecting the
>> independent component capturing the artifact will be that beneficial,
>> because most likely the spatial topography of this component of this
>> component will be confined to the three bad guys, with more or less random
>> loadings on the rest of the channels. Did you check whether the artifact is
>> present at the level of the reference sensors? If that's the case, you could
>> consider applying the cfw and afw (compute fixed weights, and apply fixed
>> weights) utilities from the 4D software.
>> Best wishes
>>
>> Jan-Mathijs
>>
>>
>> On Oct 28, 2010, at 7:11 PM, Marc Recasens wrote:
>>
>>  Dear all,
>>>
>>> I have quite a naive question.
>>> I'm processing some MEG (4-D) datasets in order to use source location
>>> methods afterwards. One of my concerns is that I have some channels (3 in a
>>> row) with a steady high frequency artifact >50Hz (I thought it is muscle
>>> activity, However it is very tonic and present during the whole recording)
>>> which is within my frequencies of interest. This can be seen in the attached
>>> figures: timelocked responses bandpass filtered between 15 and 150 Hz, and
>>> time-frequency activity between 50 and 100 Hz.
>>> As the artefactual channels are put altogether in the right edge of the
>>> sensor array (A148, A147 and A146) interpolation may not be a suitable
>>> method to eliminate those artefactual channels. (?)
>>>
>>> I was wondering whether it is possible to correct those artifacts using
>>> ICA in such a way similar to ECG artifact removal using component analysis,
>>> that is, by identifying  and remove those components in the source analysis
>>> that explain the high-frequency artifacts present in some of my channels.
>>>
>>> Thanks a lot.
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> --
>>> Marc Recasens
>>> Tel.: +34 639 24 15 98
>>>
>>> ---------------------------------------------------------------------------
>>> You are receiving this message because you are subscribed to
>>> the FieldTrip list. The aim of this list is to facilitate the discussion
>>> between users of the FieldTrip toolbox, to share experiences
>>> and to discuss new ideas for MEG and EEG analysis.
>>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>>
>>> ---------------------------------------------------------------------------
>>>
>>>
>> Dr. J.M. (Jan-Mathijs) Schoffelen Donders Institute for Brain, Cognition
>> and Behaviour, Centre for Cognitive Neuroimaging,
>> Radboud University Nijmegen, The Netherlands
>> J.Schoffelen at donders.ru.nl <mailto:J.Schoffelen at donders.ru.nl>
>> Telephone: 0031-24-3614793
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the FieldTrip list. The aim of this list is to facilitate the discussion
>> between users of the FieldTrip toolbox, to share experiences
>> and to discuss new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>
>> ---------------------------------------------------------------------------
>>
>>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>



-- 
Alexander J. Shackman, Ph.D.
Wisconsin Psychiatric Institute & Clinics and
Department of Psychology
University of Wisconsin-Madison
1202 West Johnson Street
Madison, Wisconsin 53706

Telephone: +1 (608) 358-5025
Fax: +1 (608) 265-2875
Email: shackman at wisc.edu
http://psyphz.psych.wisc.edu/~shackman

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101103/19ce1d88/attachment-0001.htm>

From shackman at WISC.EDU  Wed Nov  3 17:41:23 2010
From: shackman at WISC.EDU (Alexander J. Shackman)
Date: Wed, 3 Nov 2010 11:41:23 -0500
Subject: Remove muscle artifacts using ICA
In-Reply-To: <AANLkTi=S3q057g=T6Ta+tFhD0T0g0u1VSC4HRgtV7pUC@mail.gmail.com>
Message-ID: <WED.3.NOV.2010.114123.0500.>

and, you might also take a look at makeig's new paper on using ica to remove
artifact from EEG acquired while participants walked on a treadmill,

http://www.frontiersin.org/Human_Neuroscience/10.3389/fnhum.2010.00202/abstract


hth,
alex

On Wed, Nov 3, 2010 at 8:42 AM, Alexander J. Shackman <shackman at wisc.edu>wrote:

> re: ica
>
> you might also take a look at,
>
>
> http://psyphz.psych.wisc.edu/%7Eshackman/mcmenamin_shackman_davidson_ni2010.pdf
>
> in particular, the supplement appended to the end.
>
> good luck,
> alex
>
>
> On Wed, Nov 3, 2010 at 4:09 AM, Maarten De Vos <
> maarten.de.vos at uni-oldenburg.de> wrote:
>
>> Dear Marc,
>>
>> sometimes ICA is suboptimal for muscle artifacts.  Not always, depends
>> indeed how your data look like.
>>
>> for an alternative method, please see
>>
>> De Clercq W., Vergult A., Vanrumste B., Van Paesschen W., Van Huffel S.,
>> "Canonical Correlation Analysis Applied to Remove Muscle Artifacts From the
>> Electroencephalogram", IEEE Transactions on Biomedical Engineering, Vol.
>>  53, No. 12, December 2006, pp. 2583-2587.
>>
>> and De Vos M, Riès S, Vanderperren K, Vanrumste B, Alario FX, Van Huffel
>> S, Burle B.
>> Neuroinformatics. 2010 Jun;8(2):135-50.
>> Removal of muscle artifacts from EEG recordings of spoken language
>> production.
>>
>>
>> Hope this helps,
>> maarten
>>
>> jan-mathijs schoffelen wrote:
>>
>>> Dear Marc,
>>>
>>> Your figures seem to be missing, so it is hard to judge what the
>>> artifacts look like exactly. Could it be that one of your head localization
>>> coils was switched on througout the measurement?
>>> In general, if your goal is to do source localization, I would not try to
>>> fix ugly channels, but just omit them from the sensor-array, because there
>>> will be plenty of sensors left.
>>> The fixing operation (whatever way it is done, e.g. nearest neighbour
>>> interpolation, ICA etc) involves replacing each channel's estimate by a
>>> linear combination of a subset of/all other channels. You have to keep in
>>> mind that the solution to the forward model (i.e. the leadfields for the
>>> sources you want to estimate) have to take the same linear operation into
>>> account in order to give correct results. As such, irrespective of the fact
>>> that the noisy channels are on the edge of the array, interpolation does not
>>> really make sense, because you are not really improving the quality of your
>>> total signal array. Also, in this case, I don't expect that rejecting the
>>> independent component capturing the artifact will be that beneficial,
>>> because most likely the spatial topography of this component of this
>>> component will be confined to the three bad guys, with more or less random
>>> loadings on the rest of the channels. Did you check whether the artifact is
>>> present at the level of the reference sensors? If that's the case, you could
>>> consider applying the cfw and afw (compute fixed weights, and apply fixed
>>> weights) utilities from the 4D software.
>>> Best wishes
>>>
>>> Jan-Mathijs
>>>
>>>
>>> On Oct 28, 2010, at 7:11 PM, Marc Recasens wrote:
>>>
>>>  Dear all,
>>>>
>>>> I have quite a naive question.
>>>> I'm processing some MEG (4-D) datasets in order to use source location
>>>> methods afterwards. One of my concerns is that I have some channels (3 in a
>>>> row) with a steady high frequency artifact >50Hz (I thought it is muscle
>>>> activity, However it is very tonic and present during the whole recording)
>>>> which is within my frequencies of interest. This can be seen in the attached
>>>> figures: timelocked responses bandpass filtered between 15 and 150 Hz, and
>>>> time-frequency activity between 50 and 100 Hz.
>>>> As the artefactual channels are put altogether in the right edge of the
>>>> sensor array (A148, A147 and A146) interpolation may not be a suitable
>>>> method to eliminate those artefactual channels. (?)
>>>>
>>>> I was wondering whether it is possible to correct those artifacts using
>>>> ICA in such a way similar to ECG artifact removal using component analysis,
>>>> that is, by identifying  and remove those components in the source analysis
>>>> that explain the high-frequency artifacts present in some of my channels.
>>>>
>>>> Thanks a lot.
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Marc Recasens
>>>> Tel.: +34 639 24 15 98
>>>>
>>>> ---------------------------------------------------------------------------
>>>> You are receiving this message because you are subscribed to
>>>> the FieldTrip list. The aim of this list is to facilitate the discussion
>>>> between users of the FieldTrip toolbox, to share experiences
>>>> and to discuss new ideas for MEG and EEG analysis.
>>>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>>>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>>>
>>>> ---------------------------------------------------------------------------
>>>>
>>>>
>>> Dr. J.M. (Jan-Mathijs) Schoffelen Donders Institute for Brain, Cognition
>>> and Behaviour, Centre for Cognitive Neuroimaging,
>>> Radboud University Nijmegen, The Netherlands
>>> J.Schoffelen at donders.ru.nl <mailto:J.Schoffelen at donders.ru.nl>
>>> Telephone: 0031-24-3614793
>>>
>>> ---------------------------------------------------------------------------
>>> You are receiving this message because you are subscribed to
>>> the FieldTrip list. The aim of this list is to facilitate the discussion
>>> between users of the FieldTrip toolbox, to share experiences
>>> and to discuss new ideas for MEG and EEG analysis.
>>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>>
>>> ---------------------------------------------------------------------------
>>>
>>>
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>
>> ---------------------------------------------------------------------------
>>
>
>
>
> --
> Alexander J. Shackman, Ph.D.
> Wisconsin Psychiatric Institute & Clinics and
> Department of Psychology
> University of Wisconsin-Madison
> 1202 West Johnson Street
> Madison, Wisconsin 53706
>
> Telephone: +1 (608) 358-5025
> Fax: +1 (608) 265-2875
> Email: shackman at wisc.edu
> http://psyphz.psych.wisc.edu/~shackman<http://psyphz.psych.wisc.edu/%7Eshackman>
>



-- 
Alexander J. Shackman, Ph.D.
Wisconsin Psychiatric Institute & Clinics and
Department of Psychology
University of Wisconsin-Madison
1202 West Johnson Street
Madison, Wisconsin 53706

Telephone: +1 (608) 358-5025
Fax: +1 (608) 265-2875
Email: shackman at wisc.edu
http://psyphz.psych.wisc.edu/~shackman

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101103/32658b27/attachment-0001.htm>

From megjim1 at GMAIL.COM  Thu Nov  4 06:17:08 2010
From: megjim1 at GMAIL.COM (Jim Li)
Date: Thu, 4 Nov 2010 06:17:08 +0100
Subject: what's the planar gradient unit?
Message-ID: <THU.4.NOV.2010.061708.0100.FIELDTRIP@NIC.SURFNET.NL>

Hello,

Can anybody help answer Marcel's question? For example, after 
running "FT_MEGPLANAR" we can get a planar gradient of, say, 4.21e-13, for 
some channel. Is that number in the unit of "T/m" or what?

Thanks a lot.

Jim


On Fri, 4 May 2007 15:38:44 +0200, Marcel Bastiaansen 
<Marcel.Bastiaansen at FCDONDERS.RU.NL> wrote:

>Hi,
>
>can anyone tell me what the unit is for planar gradients? Is that fT /
>square meter, or something else?
>
>Thanks,
>Marcel
>
>--
>dr. Marcel C.M. Bastiaansen.
>
>Max Planck Institute for Psycholinguistics
>Visiting Adress: Wundtlaan 1, 6525 XD Nijmegen, the Netherlands
>Mailing adress: P.O. Box 310, 6500 AH Nijmegen, the Netherlands
>phone: +31 24 3521 347
>fax: 	 +31 24 3521 213
>mail: marcel.bastiaansen at mpi.nl
>web: http://www.mpi.nl/Members/MarcelBastiaansen
>
>and
>
>FC Donders Centre for Cognitive Neuroimaging
>Visiting address: Kapittelweg 29, 6525 EN Nijmegen, the Netherlands
>Mailing address: PO Box 9101, 6500 HB Nijmegen, the Netherlands
>phone: + 31 24 3610 882
>fax:   + 31 24 3610 989
>mail: marcel.bastiaansen at fcdonders.ru.nl
>web: http://www.ru.nl/aspx/get.aspx?
xdl=/views/run/xdl/page&ItmIdt=20592&SitIdt=119&VarIdt=96
>--
>
>----------------------------------
>The aim of this list is to facilitate the discussion between users of the 
FieldTrip  toolbox, to share experiences and to discuss new ideas for MEG and 
EEG analysis.
>  http://listserv.surfnet.nl/archives/fieldtrip.html
>  http://www.ru.nl/fcdonders/fieldtrip/

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From mark.drakesmith at POSTGRAD.MANCHESTER.AC.UK  Thu Nov  4 19:11:10 2010
From: mark.drakesmith at POSTGRAD.MANCHESTER.AC.UK (Mark Drakesmith)
Date: Thu, 4 Nov 2010 18:11:10 +0000
Subject: using reference gradiometers with preproc_denoise
Message-ID: <THU.4.NOV.2010.181110.0000.FIELDTRIP@NIC.SURFNET.NL>

Hi

I am just looking over some MEG data and was wondering what is the best
way of dealing with noise. the 4D MEG scanner includes 11 reference
coils for detecting noise within the MSR. What is the best way of using
this for data-cleaning? I am currently using preproc_denoise to do this,
but the description suggests it should be used when continuous head
motion channels are used, which is not the case here. Is it appropriate
to use preproc_denoise or should I be using an ICA-type approach?

Any help clearing up this confusion would be greatly appreciated.

Regards

Mark

--

Mark Drakesmith
PhD Student

Neuroscience and Aphasia Research Unit (NARU)
University of Manchester

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From daz at MIT.EDU  Thu Nov  4 20:24:55 2010
From: daz at MIT.EDU (David Ziegler)
Date: Thu, 4 Nov 2010 15:24:55 -0400
Subject: ft_freqstatistics between two groups
Message-ID: <THU.4.NOV.2010.152455.0400.FIELDTRIP@NIC.SURFNET.NL>

Hi Fieldtrippers,

I am trying to run a comparison between TFRs from two groups of subjects
and I keep getting some errors that I can't track down answers for.  I
seem to recall something like this being discussed on this list, but I
can't for the life of me track down that thread at the moment.

I am using data from a neuromag 306 system on which I have calculated
TFRs on the gradiometer data, then ran ft_combineplanar, followed by
ft_freqdescriptives, followed by ft_freqgrandaverage for each of the two
groups with the cfg.keepindividual = 'yes' option.  I am able to plot
the grand averages just fine, so the data seem to be ok (and there are
fairly striking differences between the two).

When I run a permutation test to quantify the group differences, I get
the following error messages (although the analysis does run):

/computing statistic 500 from 500
Warning: Not all replications are used for the computation of the statistic.
 > > In statfun_indepsamplesT at 57
   In statistics_montecarlo at 298
   In fieldtrip-20100617/private/statistics_wrapper at 285
   In ft_freqstatistics at 105
Warning: Divide by zero./

When I inspect the output file, the .stat contains a single column of
NaNs.  Does anyone know what I am doing wrong here?

Here is the actual code I am using to run the statistics:

cfg = [];
cfg.channel          = {'MEG *3'}; %only combined gradiometer data
cfg.layout = 'neuromag306cmb_dz.lay';
cfg.latency     = [0.2 0.8];
cfg.avgovertime = 'yes';
cfg.avgoverchan      = 'no';
cfg.avgoverfreq      = 'yes';
cfg.parameter   = 'powspctrm';
cfg.frequency        = [14 26];
cfg.method           = 'montecarlo';
cfg.statistic        = 'indepsamplesT';
cfg.correctm         = 'no';
cfg.clusteralpha     = 0.05;
cfg.clusterstatistic = 'maxsum';
cfg.minnbchan        = 2;
cfg.tail             = 0;
cfg.clustertail      = 0;
cfg.alpha            = 0.05;
cfg.numrandomization = 500;

cfg.design           = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
20 21 22 23 24 25 ;   % subject number
                                     1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2
2 2 2 2 2 2 2]; % 12subjs in grp1, 13subjs in grp2
cfg.uvar = 1;
cfg.ivar = 2;

GA_low_stat = ft_freqstatistics(cfg, GA_grp1_low, GA_grp2_low)

Thanks,
David


--

David A. Ziegler

Department of Brain and Cognitive Sciences
Massachusetts Institute of Technology
43 Vassar St,46-5121
Cambridge, MA 02139

Tel: 617-258-0765

Fax: 617-253-1504

daz at mit.edu <mailto:daz at mit.edu>


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101104/63dde3c4/attachment-0001.htm>

From a.stolk at FCDONDERS.RU.NL  Fri Nov  5 08:39:13 2010
From: a.stolk at FCDONDERS.RU.NL (a.stolk@fcdonders.ru.nl)
Date: Fri, 5 Nov 2010 08:39:13 +0100
Subject: ft_freqstatistics between two groups
In-Reply-To: <5040169.441471288942302823.JavaMail.root@watertor.uci.ru.nl>
Message-ID: <FRI.5.NOV.2010.083913.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi David,

Did you add the comment '%subject number' in your post or in your code? To rule out this is the bottleneck, please try the same again and use this line of code:

cfg.design = [1:25 ; ones(1,12) ones(1,13)*2];

Best,
Arjen




----- Original Message -----
From: "David Ziegler" <daz at MIT.EDU>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Thursday, November 4, 2010 8:24:55 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: [FIELDTRIP] ft_freqstatistics between two groups

Hi Fieldtrippers,

I am trying to run a comparison between TFRs from two groups of subjects
and I keep getting some errors that I can't track down answers for.  I
seem to recall something like this being discussed on this list, but I
can't for the life of me track down that thread at the moment.

I am using data from a neuromag 306 system on which I have calculated
TFRs on the gradiometer data, then ran ft_combineplanar, followed by
ft_freqdescriptives, followed by ft_freqgrandaverage for each of the two
groups with the cfg.keepindividual = 'yes' option.  I am able to plot
the grand averages just fine, so the data seem to be ok (and there are
fairly striking differences between the two).

When I run a permutation test to quantify the group differences, I get
the following error messages (although the analysis does run):

/computing statistic 500 from 500
Warning: Not all replications are used for the computation of the statistic.
 > > In statfun_indepsamplesT at 57
   In statistics_montecarlo at 298
   In fieldtrip-20100617/private/statistics_wrapper at 285
   In ft_freqstatistics at 105
Warning: Divide by zero./

When I inspect the output file, the .stat contains a single column of
NaNs.  Does anyone know what I am doing wrong here?

Here is the actual code I am using to run the statistics:

cfg = [];
cfg.channel          = {'MEG *3'}; %only combined gradiometer data
cfg.layout = 'neuromag306cmb_dz.lay';
cfg.latency     = [0.2 0.8];
cfg.avgovertime = 'yes';
cfg.avgoverchan      = 'no';
cfg.avgoverfreq      = 'yes';
cfg.parameter   = 'powspctrm';
cfg.frequency        = [14 26];
cfg.method           = 'montecarlo';
cfg.statistic        = 'indepsamplesT';
cfg.correctm         = 'no';
cfg.clusteralpha     = 0.05;
cfg.clusterstatistic = 'maxsum';
cfg.minnbchan        = 2;
cfg.tail             = 0;
cfg.clustertail      = 0;
cfg.alpha            = 0.05;
cfg.numrandomization = 500;

cfg.design           = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
20 21 22 23 24 25 ;   % subject number
                                     1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2
2 2 2 2 2 2 2]; % 12subjs in grp1, 13subjs in grp2
cfg.uvar = 1;
cfg.ivar = 2;

GA_low_stat = ft_freqstatistics(cfg, GA_grp1_low, GA_grp2_low)

Thanks,
David


--

David A. Ziegler

Department of Brain and Cognitive Sciences
Massachusetts Institute of Technology
43 Vassar St,46-5121
Cambridge, MA 02139

Tel: 617-258-0765

Fax: 617-253-1504

daz at mit.edu <mailto:daz at mit.edu>


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jan.schoffelen at DONDERS.RU.NL  Fri Nov  5 09:14:37 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Fri, 5 Nov 2010 09:14:37 +0100
Subject: ft_freqstatistics between two groups
In-Reply-To: <4CD30887.9010700@mit.edu>
Message-ID: <FRI.5.NOV.2010.091437.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi David,

It seems you are averaging both over time and frequency in
ft_freqstatistics. As far as I know, the standard mean-function is
used for that. If there are NaNs in your TFR, which happens now and
then at the edges of the TFR, you get a NaN in the average.

Cheers,

Jan-Mathijs


On Nov 4, 2010, at 8:24 PM, David Ziegler wrote:

> Hi Fieldtrippers,
>
> I am trying to run a comparison between TFRs from two groups of
> subjects and I keep getting some errors that I can't track down
> answers for.  I seem to recall something like this being discussed
> on this list, but I can't for the life of me track down that thread
> at the moment.
>
> I am using data from a neuromag 306 system on which I have
> calculated TFRs on the gradiometer data, then ran ft_combineplanar,
> followed by ft_freqdescriptives, followed by ft_freqgrandaverage for
> each of the two groups with the cfg.keepindividual = 'yes' option.
> I am able to plot the grand averages just fine, so the data seem to
> be ok (and there are fairly striking differences between the two).
>
> When I run a permutation test to quantify the group differences, I
> get the following error messages (although the analysis does run):
>
> computing statistic 500 from 500
> Warning: Not all replications are used for the computation of the
> statistic.
> > > In statfun_indepsamplesT at 57
>   In statistics_montecarlo at 298
>   In fieldtrip-20100617/private/statistics_wrapper at 285
>   In ft_freqstatistics at 105
> Warning: Divide by zero.
>
> When I inspect the output file, the .stat contains a single column
> of NaNs.  Does anyone know what I am doing wrong here?
>
> Here is the actual code I am using to run the statistics:
>
> cfg = [];
> cfg.channel          = {'MEG *3'}; %only combined gradiometer data
> cfg.layout = 'neuromag306cmb_dz.lay';
> cfg.latency     = [0.2 0.8];
> cfg.avgovertime = 'yes';
> cfg.avgoverchan      = 'no';
> cfg.avgoverfreq      = 'yes';
> cfg.parameter   = 'powspctrm';
> cfg.frequency        = [14 26];
> cfg.method           = 'montecarlo';
> cfg.statistic        = 'indepsamplesT';
> cfg.correctm         = 'no';
> cfg.clusteralpha     = 0.05;
> cfg.clusterstatistic = 'maxsum';
> cfg.minnbchan        = 2;
> cfg.tail             = 0;
> cfg.clustertail      = 0;
> cfg.alpha            = 0.05;
> cfg.numrandomization = 500;
>
> cfg.design           = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
> 19 20 21 22 23 24 25 ;   % subject number
>                                     1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2
> 2 2 2 2 2 2 2 2 2]; % 12subjs in grp1, 13subjs in grp2
> cfg.uvar = 1;
> cfg.ivar = 2;
>
> GA_low_stat = ft_freqstatistics(cfg, GA_grp1_low, GA_grp2_low)
>
> Thanks,
> David
>
>
> --
> David A. Ziegler
> Department of Brain and Cognitive Sciences
> Massachusetts Institute of Technology
> 43 Vassar St,  46-5121
> Cambridge, MA  02139
> Tel: 617-258-0765
> Fax: 617-253-1504
> daz at mit.edu
>
>
> --------------------------------------------------------------------------- You
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/d878e0f3/attachment-0001.htm>

From jan.schoffelen at DONDERS.RU.NL  Fri Nov  5 09:20:32 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Fri, 5 Nov 2010 09:20:32 +0100
Subject: using reference gradiometers with preproc_denoise
In-Reply-To: <4CD2F73E.5000306@postgrad.manchester.ac.uk>
Message-ID: <FRI.5.NOV.2010.092032.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Mark,

preproc_denoise has been specifically designed to remove the very high
amplitude coil signals generated by the 4D system when continuous head
localization is switched on. It is regressing out the signals on the
reference coils on a trial by trial basis. The signal to noise of this
artifact is huge (in fact, you don't see any brain signal when the
coils are switched on), and as a consequence of this the regression
coefficients are relatively stable across trials. In order to remove
lower amplitude environmental noise, a single trial estimate of the
regression coefficients is probably not what you want. The 4D-software
comes with the command line utitilties cfw and afw, which computes a
set of balancing coefficients given some input data (typically across
a whole dataset). Did you try to use this? I have a matlab
implementation which achieves the same thing, but it is not yet part
of general FieldTrip.

Best,

Jan-Mathijs


On Nov 4, 2010, at 7:11 PM, Mark Drakesmith wrote:

> Hi
>
> I am just looking over some MEG data and was wondering what is the
> best way of dealing with noise. the 4D MEG scanner includes 11
> reference coils for detecting noise within the MSR. What is the best
> way of using this for data-cleaning? I am currently using
> preproc_denoise to do this, but the description suggests it should
> be used when continuous head motion channels are used, which is not
> the case here. Is it appropriate to use preproc_denoise or should I
> be using an ICA-type approach?
>
> Any help clearing up this confusion would be greatly appreciated.
>
> Regards
>
> Mark
>
> --
>
> Mark Drakesmith
> PhD Student
>
> Neuroscience and Aphasia Research Unit (NARU)
> University of Manchester
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jan.schoffelen at DONDERS.RU.NL  Fri Nov  5 09:22:24 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Fri, 5 Nov 2010 09:22:24 +0100
Subject: what's the planar gradient unit?
In-Reply-To: <LISTSERV%201011040617086370.3E70@NIC.SURFNET.NL>
Message-ID: <FRI.5.NOV.2010.092224.0100.FIELDTRIP@NIC.SURFNET.NL>

FieldTrip doesn't explicitly know about the physical units (whether
it's femto nano pico kilo or mega), so it is dependent on the system.

If the magnetic field is defined in T, and the channel position in m,
I'd say the unit after planar transformation is T/m


JM

On Nov 4, 2010, at 6:17 AM, Jim Li wrote:

> Hello,
>
> Can anybody help answer Marcel's question? For example, after
> running "FT_MEGPLANAR" we can get a planar gradient of, say,
> 4.21e-13, for
> some channel. Is that number in the unit of "T/m" or what?
>
> Thanks a lot.
>
> Jim
>
>
> On Fri, 4 May 2007 15:38:44 +0200, Marcel Bastiaansen
> <Marcel.Bastiaansen at FCDONDERS.RU.NL> wrote:
>
>> Hi,
>>
>> can anyone tell me what the unit is for planar gradients? Is that
>> fT /
>> square meter, or something else?
>>
>> Thanks,
>> Marcel
>>
>> --
>> dr. Marcel C.M. Bastiaansen.
>>
>> Max Planck Institute for Psycholinguistics
>> Visiting Adress: Wundtlaan 1, 6525 XD Nijmegen, the Netherlands
>> Mailing adress: P.O. Box 310, 6500 AH Nijmegen, the Netherlands
>> phone: +31 24 3521 347
>> fax: 	 +31 24 3521 213
>> mail: marcel.bastiaansen at mpi.nl
>> web: http://www.mpi.nl/Members/MarcelBastiaansen
>>
>> and
>>
>> FC Donders Centre for Cognitive Neuroimaging
>> Visiting address: Kapittelweg 29, 6525 EN Nijmegen, the Netherlands
>> Mailing address: PO Box 9101, 6500 HB Nijmegen, the Netherlands
>> phone: + 31 24 3610 882
>> fax:   + 31 24 3610 989
>> mail: marcel.bastiaansen at fcdonders.ru.nl
>> web: http://www.ru.nl/aspx/get.aspx?
> xdl=/views/run/xdl/page&ItmIdt=20592&SitIdt=119&VarIdt=96
>> --
>>
>> ----------------------------------
>> The aim of this list is to facilitate the discussion between users
>> of the
> FieldTrip  toolbox, to share experiences and to discuss new ideas
> for MEG and
> EEG analysis.
>> http://listserv.surfnet.nl/archives/fieldtrip.html
>> http://www.ru.nl/fcdonders/fieldtrip/
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From mark.drakesmith at POSTGRAD.MANCHESTER.AC.UK  Fri Nov  5 10:15:07 2010
From: mark.drakesmith at POSTGRAD.MANCHESTER.AC.UK (Mark Drakesmith)
Date: Fri, 5 Nov 2010 09:15:07 +0000
Subject: using reference gradiometers with preproc_denoise
In-Reply-To: <2638807A-3D59-4E2E-9E9F-366032EF63D0@donders.ru.nl>
Message-ID: <FRI.5.NOV.2010.091507.0000.FIELDTRIP@NIC.SURFNET.NL>

Thanks for the clarification. That's very helpful. I was not aware of the cfw and afw commands. Would it be possible to obtain the matlab scripts? Our 4d machine is now out of service so accessing the 4d software may be difficult. 
 
Thanks again

Mark Drakesmith


On 5 Nov 2010, at 08:20, jan-mathijs schoffelen <jan.schoffelen at DONDERS.RU.NL> wrote:

> Dear Mark,
> 
> preproc_denoise has been specifically designed to remove the very high amplitude coil signals generated by the 4D system when continuous head localization is switched on. It is regressing out the signals on the reference coils on a trial by trial basis. The signal to noise of this artifact is huge (in fact, you don't see any brain signal when the coils are switched on), and as a consequence of this the regression coefficients are relatively stable across trials. In order to remove lower amplitude environmental noise, a single trial estimate of the regression coefficients is probably not what you want. The 4D-software comes with the command line utitilties cfw and afw, which computes a set of balancing coefficients given some input data (typically across a whole dataset). Did you try to use this? I have a matlab implementation which achieves the same thing, but it is not yet part of general FieldTrip.
> 
> Best,
> 
> Jan-Mathijs
> 
> 
> On Nov 4, 2010, at 7:11 PM, Mark Drakesmith wrote:
> 
>> Hi
>> 
>> I am just looking over some MEG data and was wondering what is the best way of dealing with noise. the 4D MEG scanner includes 11 reference coils for detecting noise within the MSR. What is the best way of using this for data-cleaning? I am currently using preproc_denoise to do this, but the description suggests it should be used when continuous head motion channels are used, which is not the case here. Is it appropriate to use preproc_denoise or should I be using an ICA-type approach?
>> 
>> Any help clearing up this confusion would be greatly appreciated.
>> 
>> Regards
>> 
>> Mark
>> 
>> -- 
>> 
>> Mark Drakesmith
>> PhD Student
>> 
>> Neuroscience and Aphasia Research Unit (NARU)
>> University of Manchester
>> 
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>> 
> 
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl
> Telephone: 0031-24-3614793
> 
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jan.schoffelen at DONDERS.RU.NL  Fri Nov  5 11:07:32 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Fri, 5 Nov 2010 11:07:32 +0100
Subject: using reference gradiometers with preproc_denoise
In-Reply-To: <FFDBAA8B-A304-447D-9842-DAFF6E7D1506@postgrad.manchester.ac.uk>
Message-ID: <FRI.5.NOV.2010.110732.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Mark,

Adding this functionality to the fieldtrip release is on my to do
list. I'll let you know when it's there.

Best,

JM

On Nov 5, 2010, at 10:15 AM, Mark Drakesmith wrote:

> Thanks for the clarification. That's very helpful. I was not aware
> of the cfw and afw commands. Would it be possible to obtain the
> matlab scripts? Our 4d machine is now out of service so accessing
> the 4d software may be difficult.
>
> Thanks again
>
> Mark Drakesmith
>
>
> On 5 Nov 2010, at 08:20, jan-mathijs schoffelen <jan.schoffelen at DONDERS.RU.NL
> > wrote:
>
>> Dear Mark,
>>
>> preproc_denoise has been specifically designed to remove the very
>> high amplitude coil signals generated by the 4D system when
>> continuous head localization is switched on. It is regressing out
>> the signals on the reference coils on a trial by trial basis. The
>> signal to noise of this artifact is huge (in fact, you don't see
>> any brain signal when the coils are switched on), and as a
>> consequence of this the regression coefficients are relatively
>> stable across trials. In order to remove lower amplitude
>> environmental noise, a single trial estimate of the regression
>> coefficients is probably not what you want. The 4D-software comes
>> with the command line utitilties cfw and afw, which computes a set
>> of balancing coefficients given some input data (typically across a
>> whole dataset). Did you try to use this? I have a matlab
>> implementation which achieves the same thing, but it is not yet
>> part of general FieldTrip.
>>
>> Best,
>>
>> Jan-Mathijs
>>
>>
>> On Nov 4, 2010, at 7:11 PM, Mark Drakesmith wrote:
>>
>>> Hi
>>>
>>> I am just looking over some MEG data and was wondering what is the
>>> best way of dealing with noise. the 4D MEG scanner includes 11
>>> reference coils for detecting noise within the MSR. What is the
>>> best way of using this for data-cleaning? I am currently using
>>> preproc_denoise to do this, but the description suggests it should
>>> be used when continuous head motion channels are used, which is
>>> not the case here. Is it appropriate to use preproc_denoise or
>>> should I be using an ICA-type approach?
>>>
>>> Any help clearing up this confusion would be greatly appreciated.
>>>
>>> Regards
>>>
>>> Mark
>>>
>>> --
>>>
>>> Mark Drakesmith
>>> PhD Student
>>>
>>> Neuroscience and Aphasia Research Unit (NARU)
>>> University of Manchester
>>>
>>> ---------------------------------------------------------------------------
>>> You are receiving this message because you are subscribed to
>>> the  FieldTrip list. The aim of this list is to facilitate the
>>> discussion
>>> between  users of the FieldTrip  toolbox, to share experiences
>>> and to discuss  new ideas for MEG and EEG analysis.
>>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>> ---------------------------------------------------------------------------
>>>
>>
>> Dr. J.M. (Jan-Mathijs) Schoffelen
>> Donders Institute for Brain, Cognition and Behaviour,
>> Centre for Cognitive Neuroimaging,
>> Radboud University Nijmegen, The Netherlands
>> J.Schoffelen at donders.ru.nl
>> Telephone: 0031-24-3614793
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From megjim1 at GMAIL.COM  Fri Nov  5 15:18:26 2010
From: megjim1 at GMAIL.COM (Jim Li)
Date: Fri, 5 Nov 2010 15:18:26 +0100
Subject: what's the planar gradient unit?
Message-ID: <FRI.5.NOV.2010.151826.0100.FIELDTRIP@NIC.SURFNET.NL>

That's good to know. Thanks a lot, jan-mathijs, :)

Jim


On Fri, 5 Nov 2010 09:22:24 +0100, jan-mathijs schoffelen 
<jan.schoffelen at DONDERS.RU.NL> wrote:

>FieldTrip doesn't explicitly know about the physical units (whether
>it's femto nano pico kilo or mega), so it is dependent on the system.
>
>If the magnetic field is defined in T, and the channel position in m,
>I'd say the unit after planar transformation is T/m
>
>
>JM
>
>On Nov 4, 2010, at 6:17 AM, Jim Li wrote:
>
>> Hello,
>>
>> Can anybody help answer Marcel's question? For example, after
>> running "FT_MEGPLANAR" we can get a planar gradient of, say,
>> 4.21e-13, for
>> some channel. Is that number in the unit of "T/m" or what?
>>
>> Thanks a lot.
>>
>> Jim
>>
>>
>> On Fri, 4 May 2007 15:38:44 +0200, Marcel Bastiaansen
>> <Marcel.Bastiaansen at FCDONDERS.RU.NL> wrote:
>>
>>> Hi,
>>>
>>> can anyone tell me what the unit is for planar gradients? Is that
>>> fT /
>>> square meter, or something else?
>>>
>>> Thanks,
>>> Marcel
>>>
>>> --
>>> dr. Marcel C.M. Bastiaansen.
>>>
>>> Max Planck Institute for Psycholinguistics
>>> Visiting Adress: Wundtlaan 1, 6525 XD Nijmegen, the Netherlands
>>> Mailing adress: P.O. Box 310, 6500 AH Nijmegen, the Netherlands
>>> phone: +31 24 3521 347
>>> fax: 	 +31 24 3521 213
>>> mail: marcel.bastiaansen at mpi.nl
>>> web: http://www.mpi.nl/Members/MarcelBastiaansen
>>>
>>> and
>>>
>>> FC Donders Centre for Cognitive Neuroimaging
>>> Visiting address: Kapittelweg 29, 6525 EN Nijmegen, the Netherlands
>>> Mailing address: PO Box 9101, 6500 HB Nijmegen, the Netherlands
>>> phone: + 31 24 3610 882
>>> fax:   + 31 24 3610 989
>>> mail: marcel.bastiaansen at fcdonders.ru.nl
>>> web: http://www.ru.nl/aspx/get.aspx?
>> xdl=/views/run/xdl/page&ItmIdt=20592&SitIdt=119&VarIdt=96
>>> --
>>>
>>> ----------------------------------
>>> The aim of this list is to facilitate the discussion between users
>>> of the
>> FieldTrip  toolbox, to share experiences and to discuss new ideas
>> for MEG and
>> EEG analysis.
>>> http://listserv.surfnet.nl/archives/fieldtrip.html
>>> http://www.ru.nl/fcdonders/fieldtrip/
>>
>> ------------------------------------------------------------------------
---
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ------------------------------------------------------------------------
---
>>
>
>Dr. J.M. (Jan-Mathijs) Schoffelen
>Donders Institute for Brain, Cognition and Behaviour,
>Centre for Cognitive Neuroimaging,
>Radboud University Nijmegen, The Netherlands
>J.Schoffelen at donders.ru.nl
>Telephone: 0031-24-3614793
>
>--------------------------------------------------------------------------
-
>You are receiving this message because you are subscribed to
>the  FieldTrip list. The aim of this list is to facilitate the discussion
>between  users of the FieldTrip  toolbox, to share experiences
>and to discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>--------------------------------------------------------------------------
-

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From Antony.Passaro at UTH.TMC.EDU  Fri Nov  5 16:47:32 2010
From: Antony.Passaro at UTH.TMC.EDU (Passaro, Antony D)
Date: Fri, 5 Nov 2010 10:47:32 -0500
Subject: specifying individual lateralization in sourcestatistic
In-Reply-To: <551388379.1832555.1287151689447.JavaMail.fmail@mwmweb053>
Message-ID: <FRI.5.NOV.2010.104732.0500.FIELDTRIP@NIC.SURFNET.NL>

Hi Michael (or anyone else),

I had a question in regards to your comment in this email, specifically where you mention obtaining t-values from first level statistics. In the example on the Fieldtrip website, ft_sourcestatistics describes a method of obtaining the t-values when comparing conditions directly but I was wondering how it might be possible to obtain the t-values by using source statistics for a task-vs-basline comparison for one condition? More specifically, what would have to be changed in the example from the website (posted below)?

cfg = [];
cfg.dim         = source.dim;
cfg.method      = 'montecarlo';
cfg.statistic   = 'indepsamplesT';
cfg.parameter   = 'pow';
cfg.correctm    = 'cluster';
cfg.numrandomization = 1000;
cfg.alpha       = 0.05;
cfg.tail        = 0;
cfg.design(1,:) = [1:length(find(design==1)) 1:length(find(design==2))];
cfg.design(2,:) = design;
cfg.uvar        = 1; % row of design matrix that contains unit variable (in this case: trials)
cfg.ivar        = 2; % row of design matrix that contains independent variable (the conditions)

stat = ft_sourcestatistics(cfg, source);


Thank you very much for your help,
-Tony



-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Michael Wibral
Sent: Friday, October 15, 2010 9:08 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Thomas,

I suggest you simply extract the power values from the results of sourceanalysis (or t-values if you already did a fisrt level statistics) and average them by hand in MATLAB - as ROI is known for each subject this should be easy (you have to extract the values by the voxel indices contained in your ROI. These in turn you can find in interactive mode source plotting if everything else fails). This way you end up with a single value per subject and condition. Afterwards you do a simple permutation test by hand in MATLAB. 

((The test for two conditions for example can be done this way:
1. concatenate all data in a vector D first data in one condition, then in the other) 2. compute your test metric between first and second half of D.
3. shuffle the entries of D: DS=D(randperm(length(D)); % creates a new D with shuffled entries by shuffling the indexes of the old one 4. compute your test metric for DS and remember it 5. Do 3+4 N times (e.g. >1901 times for accurate testing at alpha<0.05) 6. check where your original test metric obtained from D is in the distribution of the mtrices obtained from the DS.))


Hope this helps,
Michael

-----Ursprüngliche Nachricht-----
Von: "Thomas Hartmann" <thomas.hartmann at UNI-KONSTANZ.DE>
Gesendet: Oct 15, 2010 3:30:40 PM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: [FIELDTRIP] specifying individual lateralization in sourcestatistic

>  hi,
>i want to do a roi analysis on source data and average over the all the 
>voxels. the problem is that i am dealing with a lateralized effect that 
>i expect to show up either on the left or the right side of the same 
>structure. this lateralization is individual for each subject and known 
>a priori.
>is there any possibility to individually define, which side to take 
>into account for the statistics?
>
>thanks in advance,
>thomas
>
>--
>Dipl. Psych. Thomas Hartmann
>
>OBOB-Lab
>University of Konstanz
>Department of Psychology
>P.O. Box D25
>78457 Konstanz
>Germany
>
>Tel.: +49 (0)7531 88 4612
>Fax: +49 (0)7531-88 4601
>Email: thomas.hartmann at uni-konstanz.de
>Homepage: http://www.uni-konstanz.de/obob
>
>"I am a brain, Watson. The rest of me is a mere appendix. " (Arthur 
>Conan Doyle)
>
>-----------------------------------------------------------------------
>---- You are receiving this message because you are subscribed to the  
>FieldTrip list. The aim of this list is to facilitate the discussion 
>between  users of the FieldTrip  toolbox, to share experiences and to 
>discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>-----------------------------------------------------------------------
>----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to the  FieldTrip list. The aim of this list is to facilitate the discussion between  users of the FieldTrip  toolbox, to share experiences and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

From a.stolk at FCDONDERS.RU.NL  Fri Nov  5 17:12:17 2010
From: a.stolk at FCDONDERS.RU.NL (a.stolk@fcdonders.ru.nl)
Date: Fri, 5 Nov 2010 17:12:17 +0100
Subject: specifying individual lateralization in sourcestatistic
In-Reply-To: <10744934.455691288973075576.JavaMail.root@watertor.uci.ru.nl>
Message-ID: <FRI.5.NOV.2010.171217.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi Tony,

Basically, you'd only need to change these lines. 

cfg.design = [(ones(1,Ntrials) ones(1,Ntrials)*2];
cfg.ivar = 1; 

stat =  ft_sourcestatistics(cfg, source_task, source_baseline);

Note that you want the SNR of your baseline segments and the task segments to be the same. You'll have to make sure you'll have as many baseline cross-spectral-density matrices (output from your fourieranalysis) as task CSD matrices.

Best regards,
Arjen


----- Original Message -----
From: "Antony D Passaro" <Antony.Passaro at UTH.TMC.EDU>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Friday, November 5, 2010 4:47:32 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Michael (or anyone else),

I had a question in regards to your comment in this email, specifically where you mention obtaining t-values from first level statistics. In the example on the Fieldtrip website, ft_sourcestatistics describes a method of obtaining the t-values when comparing conditions directly but I was wondering how it might be possible to obtain the t-values by using source statistics for a task-vs-basline comparison for one condition? More specifically, what would have to be changed in the example from the website (posted below)?

cfg = [];
cfg.dim         = source.dim;
cfg.method      = 'montecarlo';
cfg.statistic   = 'indepsamplesT';
cfg.parameter   = 'pow';
cfg.correctm    = 'cluster';
cfg.numrandomization = 1000;
cfg.alpha       = 0.05;
cfg.tail        = 0;
cfg.design(1,:) = [1:length(find(design==1)) 1:length(find(design==2))];
cfg.design(2,:) = design;
cfg.uvar        = 1; % row of design matrix that contains unit variable (in this case: trials)
cfg.ivar        = 2; % row of design matrix that contains independent variable (the conditions)

stat = ft_sourcestatistics(cfg, source);


Thank you very much for your help,
-Tony



-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Michael Wibral
Sent: Friday, October 15, 2010 9:08 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Thomas,

I suggest you simply extract the power values from the results of sourceanalysis (or t-values if you already did a fisrt level statistics) and average them by hand in MATLAB - as ROI is known for each subject this should be easy (you have to extract the values by the voxel indices contained in your ROI. These in turn you can find in interactive mode source plotting if everything else fails). This way you end up with a single value per subject and condition. Afterwards you do a simple permutation test by hand in MATLAB. 

((The test for two conditions for example can be done this way:
1. concatenate all data in a vector D first data in one condition, then in the other) 2. compute your test metric between first and second half of D.
3. shuffle the entries of D: DS=D(randperm(length(D)); % creates a new D with shuffled entries by shuffling the indexes of the old one 4. compute your test metric for DS and remember it 5. Do 3+4 N times (e.g. >1901 times for accurate testing at alpha<0.05) 6. check where your original test metric obtained from D is in the distribution of the mtrices obtained from the DS.))


Hope this helps,
Michael

-----Ursprüngliche Nachricht-----
Von: "Thomas Hartmann" <thomas.hartmann at UNI-KONSTANZ.DE>
Gesendet: Oct 15, 2010 3:30:40 PM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: [FIELDTRIP] specifying individual lateralization in sourcestatistic

>  hi,
>i want to do a roi analysis on source data and average over the all the 
>voxels. the problem is that i am dealing with a lateralized effect that 
>i expect to show up either on the left or the right side of the same 
>structure. this lateralization is individual for each subject and known 
>a priori.
>is there any possibility to individually define, which side to take 
>into account for the statistics?
>
>thanks in advance,
>thomas
>
>--
>Dipl. Psych. Thomas Hartmann
>
>OBOB-Lab
>University of Konstanz
>Department of Psychology
>P.O. Box D25
>78457 Konstanz
>Germany
>
>Tel.: +49 (0)7531 88 4612
>Fax: +49 (0)7531-88 4601
>Email: thomas.hartmann at uni-konstanz.de
>Homepage: http://www.uni-konstanz.de/obob
>
>"I am a brain, Watson. The rest of me is a mere appendix. " (Arthur 
>Conan Doyle)
>
>-----------------------------------------------------------------------
>---- You are receiving this message because you are subscribed to the  
>FieldTrip list. The aim of this list is to facilitate the discussion 
>between  users of the FieldTrip  toolbox, to share experiences and to 
>discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>-----------------------------------------------------------------------
>----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to the  FieldTrip list. The aim of this list is to facilitate the discussion between  users of the FieldTrip  toolbox, to share experiences and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From Antony.Passaro at UTH.TMC.EDU  Fri Nov  5 17:30:10 2010
From: Antony.Passaro at UTH.TMC.EDU (Passaro, Antony D)
Date: Fri, 5 Nov 2010 11:30:10 -0500
Subject: specifying individual lateralization in sourcestatistic
In-Reply-To: <12066090.455991288973537890.JavaMail.root@watertor.uci.ru.nl>
Message-ID: <FRI.5.NOV.2010.113010.0500.FIELDTRIP@NIC.SURFNET.NL>

Hi Arjen,

Thank you very much for your reply, that was very helpful. I was wondering would source_task and source_baseline come straight from ft_sourceanalysis or would I first redefine avg.pow in terms of task - baseline / baseline (as in the sourceanalysis example on the Fieldtrip website)?

Thank you,
-Tony 

-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of a.stolk at fcdonders.ru.nl
Sent: Friday, November 05, 2010 11:12 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Tony,

Basically, you'd only need to change these lines. 

cfg.design = [(ones(1,Ntrials) ones(1,Ntrials)*2];
cfg.ivar = 1; 

stat =  ft_sourcestatistics(cfg, source_task, source_baseline);

Note that you want the SNR of your baseline segments and the task segments to be the same. You'll have to make sure you'll have as many baseline cross-spectral-density matrices (output from your fourieranalysis) as task CSD matrices.

Best regards,
Arjen


----- Original Message -----
From: "Antony D Passaro" <Antony.Passaro at UTH.TMC.EDU>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Friday, November 5, 2010 4:47:32 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Michael (or anyone else),

I had a question in regards to your comment in this email, specifically where you mention obtaining t-values from first level statistics. In the example on the Fieldtrip website, ft_sourcestatistics describes a method of obtaining the t-values when comparing conditions directly but I was wondering how it might be possible to obtain the t-values by using source statistics for a task-vs-basline comparison for one condition? More specifically, what would have to be changed in the example from the website (posted below)?

cfg = [];
cfg.dim         = source.dim;
cfg.method      = 'montecarlo';
cfg.statistic   = 'indepsamplesT';
cfg.parameter   = 'pow';
cfg.correctm    = 'cluster';
cfg.numrandomization = 1000;
cfg.alpha       = 0.05;
cfg.tail        = 0;
cfg.design(1,:) = [1:length(find(design==1)) 1:length(find(design==2))];
cfg.design(2,:) = design;
cfg.uvar        = 1; % row of design matrix that contains unit variable (in this case: trials)
cfg.ivar        = 2; % row of design matrix that contains independent variable (the conditions)

stat = ft_sourcestatistics(cfg, source);


Thank you very much for your help,
-Tony



-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Michael Wibral
Sent: Friday, October 15, 2010 9:08 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Thomas,

I suggest you simply extract the power values from the results of sourceanalysis (or t-values if you already did a fisrt level statistics) and average them by hand in MATLAB - as ROI is known for each subject this should be easy (you have to extract the values by the voxel indices contained in your ROI. These in turn you can find in interactive mode source plotting if everything else fails). This way you end up with a single value per subject and condition. Afterwards you do a simple permutation test by hand in MATLAB. 

((The test for two conditions for example can be done this way:
1. concatenate all data in a vector D first data in one condition, then in the other) 2. compute your test metric between first and second half of D.
3. shuffle the entries of D: DS=D(randperm(length(D)); % creates a new D with shuffled entries by shuffling the indexes of the old one 4. compute your test metric for DS and remember it 5. Do 3+4 N times (e.g. >1901 times for accurate testing at alpha<0.05) 6. check where your original test metric obtained from D is in the distribution of the mtrices obtained from the DS.))


Hope this helps,
Michael

-----Ursprüngliche Nachricht-----
Von: "Thomas Hartmann" <thomas.hartmann at UNI-KONSTANZ.DE>
Gesendet: Oct 15, 2010 3:30:40 PM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: [FIELDTRIP] specifying individual lateralization in sourcestatistic

>  hi,
>i want to do a roi analysis on source data and average over the all the 
>voxels. the problem is that i am dealing with a lateralized effect that 
>i expect to show up either on the left or the right side of the same 
>structure. this lateralization is individual for each subject and known 
>a priori.
>is there any possibility to individually define, which side to take 
>into account for the statistics?
>
>thanks in advance,
>thomas
>
>--
>Dipl. Psych. Thomas Hartmann
>
>OBOB-Lab
>University of Konstanz
>Department of Psychology
>P.O. Box D25
>78457 Konstanz
>Germany
>
>Tel.: +49 (0)7531 88 4612
>Fax: +49 (0)7531-88 4601
>Email: thomas.hartmann at uni-konstanz.de
>Homepage: http://www.uni-konstanz.de/obob
>
>"I am a brain, Watson. The rest of me is a mere appendix. " (Arthur 
>Conan Doyle)
>
>-----------------------------------------------------------------------
>---- You are receiving this message because you are subscribed to the  
>FieldTrip list. The aim of this list is to facilitate the discussion 
>between  users of the FieldTrip  toolbox, to share experiences and to 
>discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>-----------------------------------------------------------------------
>----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to the  FieldTrip list. The aim of this list is to facilitate the discussion between  users of the FieldTrip  toolbox, to share experiences and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

From a.stolk at FCDONDERS.RU.NL  Fri Nov  5 17:48:17 2010
From: a.stolk at FCDONDERS.RU.NL (a.stolk@fcdonders.ru.nl)
Date: Fri, 5 Nov 2010 17:48:17 +0100
Subject: specifying individual lateralization in sourcestatistic
In-Reply-To: <9900065.456561288974816996.JavaMail.root@watertor.uci.ru.nl>
Message-ID: <FRI.5.NOV.2010.174817.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi Tony,

Appreciated. The answer to your question depends on what your data looks like and the conclusions you'd like to draw.

1) A baseline-correction might come in handy if you have more task trials than baseline trials. What happens, is that for every every task trial the relative difference is taken against the average of the baselines. At the second level of your analysis, only the average per subject of the relative differences is taken.

Here, the procedure is:
-frequency analysis
-baseline correction
-source analysis 
-sourcegrandaverage
-sourcestatistics

2) When you do T-statistics on tasks vs baselines, the standard deviation plays a role in the computation of your T values which then is a more robust estimate of the difference at the subject level. Preferably you use common filters when doing sourceanalysis as the average spatial filter then is based on more trials (greater SNR). Have a look at our page;   

http://fieldtrip.fcdonders.nl/example/common_filters_in_beamforming

Here, the procedure is:
-source analysis (common filter)
-split the source data into task and baseline
-sourcestatistics 
-sourcegrandaverage
-sourcestatistics


Best regards,
Arjen



----- Original Message -----
From: "Antony D Passaro" <Antony.Passaro at UTH.TMC.EDU>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Friday, November 5, 2010 5:30:10 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Arjen,

Thank you very much for your reply, that was very helpful. I was wondering would source_task and source_baseline come straight from ft_sourceanalysis or would I first redefine avg.pow in terms of task - baseline / baseline (as in the sourceanalysis example on the Fieldtrip website)?

Thank you,
-Tony 

-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of a.stolk at fcdonders.ru.nl
Sent: Friday, November 05, 2010 11:12 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Tony,

Basically, you'd only need to change these lines. 

cfg.design = [(ones(1,Ntrials) ones(1,Ntrials)*2];
cfg.ivar = 1; 

stat =  ft_sourcestatistics(cfg, source_task, source_baseline);

Note that you want the SNR of your baseline segments and the task segments to be the same. You'll have to make sure you'll have as many baseline cross-spectral-density matrices (output from your fourieranalysis) as task CSD matrices.

Best regards,
Arjen


----- Original Message -----
From: "Antony D Passaro" <Antony.Passaro at UTH.TMC.EDU>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Friday, November 5, 2010 4:47:32 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Michael (or anyone else),

I had a question in regards to your comment in this email, specifically where you mention obtaining t-values from first level statistics. In the example on the Fieldtrip website, ft_sourcestatistics describes a method of obtaining the t-values when comparing conditions directly but I was wondering how it might be possible to obtain the t-values by using source statistics for a task-vs-basline comparison for one condition? More specifically, what would have to be changed in the example from the website (posted below)?

cfg = [];
cfg.dim         = source.dim;
cfg.method      = 'montecarlo';
cfg.statistic   = 'indepsamplesT';
cfg.parameter   = 'pow';
cfg.correctm    = 'cluster';
cfg.numrandomization = 1000;
cfg.alpha       = 0.05;
cfg.tail        = 0;
cfg.design(1,:) = [1:length(find(design==1)) 1:length(find(design==2))];
cfg.design(2,:) = design;
cfg.uvar        = 1; % row of design matrix that contains unit variable (in this case: trials)
cfg.ivar        = 2; % row of design matrix that contains independent variable (the conditions)

stat = ft_sourcestatistics(cfg, source);


Thank you very much for your help,
-Tony



-----Original Message-----
From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Michael Wibral
Sent: Friday, October 15, 2010 9:08 AM
To: FIELDTRIP at NIC.SURFNET.NL
Subject: Re: [FIELDTRIP] specifying individual lateralization in sourcestatistic

Hi Thomas,

I suggest you simply extract the power values from the results of sourceanalysis (or t-values if you already did a fisrt level statistics) and average them by hand in MATLAB - as ROI is known for each subject this should be easy (you have to extract the values by the voxel indices contained in your ROI. These in turn you can find in interactive mode source plotting if everything else fails). This way you end up with a single value per subject and condition. Afterwards you do a simple permutation test by hand in MATLAB. 

((The test for two conditions for example can be done this way:
1. concatenate all data in a vector D first data in one condition, then in the other) 2. compute your test metric between first and second half of D.
3. shuffle the entries of D: DS=D(randperm(length(D)); % creates a new D with shuffled entries by shuffling the indexes of the old one 4. compute your test metric for DS and remember it 5. Do 3+4 N times (e.g. >1901 times for accurate testing at alpha<0.05) 6. check where your original test metric obtained from D is in the distribution of the mtrices obtained from the DS.))


Hope this helps,
Michael

-----Ursprüngliche Nachricht-----
Von: "Thomas Hartmann" <thomas.hartmann at UNI-KONSTANZ.DE>
Gesendet: Oct 15, 2010 3:30:40 PM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: [FIELDTRIP] specifying individual lateralization in sourcestatistic

>  hi,
>i want to do a roi analysis on source data and average over the all the 
>voxels. the problem is that i am dealing with a lateralized effect that 
>i expect to show up either on the left or the right side of the same 
>structure. this lateralization is individual for each subject and known 
>a priori.
>is there any possibility to individually define, which side to take 
>into account for the statistics?
>
>thanks in advance,
>thomas
>
>--
>Dipl. Psych. Thomas Hartmann
>
>OBOB-Lab
>University of Konstanz
>Department of Psychology
>P.O. Box D25
>78457 Konstanz
>Germany
>
>Tel.: +49 (0)7531 88 4612
>Fax: +49 (0)7531-88 4601
>Email: thomas.hartmann at uni-konstanz.de
>Homepage: http://www.uni-konstanz.de/obob
>
>"I am a brain, Watson. The rest of me is a mere appendix. " (Arthur 
>Conan Doyle)
>
>-----------------------------------------------------------------------
>---- You are receiving this message because you are subscribed to the  
>FieldTrip list. The aim of this list is to facilitate the discussion 
>between  users of the FieldTrip  toolbox, to share experiences and to 
>discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>-----------------------------------------------------------------------
>----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to the  FieldTrip list. The aim of this list is to facilitate the discussion between  users of the FieldTrip  toolbox, to share experiences and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From l.frei at PSY.GLA.AC.UK  Fri Nov  5 18:29:16 2010
From: l.frei at PSY.GLA.AC.UK (Luisa Frei)
Date: Fri, 5 Nov 2010 17:29:16 +0000
Subject: ft_appenddata and denoise_pca causing problems
Message-ID: <FRI.5.NOV.2010.172916.0000.FIELDTRIP@NIC.SURFNET.NL>

>
> Hi,
> I'm sorry if this has been discussed before and if it has, could
> you please direct me to the relevant emails? Thanks.
>
> I am encountering a problem when using ft_appenddata and
> denoise_pca. My MEG experiment  (4D) consists of 10 blocks per
> session, for each of which I have a separate data set.
>
> During preprocessing (after artifact rejection), I concatenate
> these data sets to find denoising weights per session using the
> function denoise_pca for 4D (I do this on shorter 400 ms epochs to
> save computational power). Afterwards, I apply these weights per
> block, downsample the data and concatenate the resulting data again
> in order to do an ICA per session to remove heart beat artifacts. I
> downsample because I use longer epochs to do that (1.5 sec).
>
> However, when I do an ICA on the denoised and concatenated session,
> I get lots of high variance noise components (first figure):
>

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 12.png
Type: application/applefile
Size: 74 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment-0003.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 12.png
Type: image/png
Size: 181659 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment-0003.png>
-------------- next part --------------
>
> Trying to find the root of this, I went back and did this analysis
> for one block only (denoising for one block, no concatenating) and
> the result looks much better (second figure):

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 10.png
Type: application/applefile
Size: 74 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment-0004.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 10.png
Type: image/png
Size: 171390 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment-0004.png>
-------------- next part --------------
>
>
> Then, as a test, I tried to concatenate two blocks, find the
> weights for those two concatenated blocks, apply them to the
> individual blocks, concatenate again and do the ICA on these two
> blocks and I get this (last figure):

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 11.png
Type: application/applefile
Size: 74 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment-0005.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Picture 11.png
Type: image/png
Size: 167953 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101105/f6b1eaa3/attachment-0005.png>
-------------- next part --------------
>
>
> So, it seems like when denoising per session (the concatenated
> blocks), I introduce noise when I apply the pca weights to the
> individual blocks. Whereas the whole point of the exercise was to
> reduce noise by denoising per session rather than block.
>
> Why is this? Am I doing something fundamentally wrong? I'm
> wondering because a colleague of mine has done an almost identical
> analysis step a while ago and she doesn't get problems with high
> variance noise components. I'm not sure whether the problem lies
> with append_data or denoise-pca, but I know that append_data has
> been changed recently, so this might be one possible source of the
> problem.
>
> I'm relatively new to MEG analysis, so I would be grateful for any
> pointers.
>
> Thanks,
> Luisa
>
> PS: I know that the different head positions between blocks can
> introduce noise, but when comparing the error introduced by head
> movements and the error introduced by correcting for head
> movements, the error was comparable, so correcting the head
> positions doesn't seem worth the effort.
>
>
>
>
>
>


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

From jan.schoffelen at DONDERS.RU.NL  Mon Nov  8 09:07:37 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Mon, 8 Nov 2010 09:07:37 +0100
Subject: ft_appenddata and denoise_pca causing problems
In-Reply-To: <01F75A80-9F52-4956-85B4-CEE86BE9AE71@psy.gla.ac.uk>
Message-ID: <MON.8.NOV.2010.090737.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Luisa,

>
> Hi,
> I'm sorry if this has been discussed before and if it has, could you
> please direct me to the relevant emails? Thanks.
>
Don't worry. This has not yet been discussed here before, and it's an
interesting issue. Yet, probably most people wouldn't know what you
are talking about, because the function denoise_pca is not yet part of
the FieldTrip release version ;o). At the moment, it's only the CCNi
and the fcdc who have it available.

> I am encountering a problem when using ft_appenddata and
> denoise_pca. My MEG experiment  (4D) consists of 10 blocks per
> session, for each of which I have a separate data set.
>
> During preprocessing (after artifact rejection), I concatenate these
> data sets to find denoising weights per session using the function
> denoise_pca for 4D (I do this on shorter 400 ms epochs to save
> computational power). Afterwards, I apply these weights per block,
> downsample the data and concatenate the resulting data again in
> order to do an ICA per session to remove heart beat artifacts. I
> downsample because I use longer epochs to do that (1.5 sec).
> However, when I do an ICA on the denoised and concatenated session,
> I get lots of high variance noise components (first figure):
> Trying to find the root of this, I went back and did this analysis
> for one block only (denoising for one block, no concatenating) and
> the result looks much better (second figure):
> Then, as a test, I tried to concatenate two blocks, find the weights
> for those two concatenated blocks, apply them to the individual
> blocks, concatenate again and do the ICA on these two blocks and I
> get this (last figure):
> So, it seems like when denoising per session (the concatenated
> blocks), I introduce noise when I apply the pca weights to the
> individual blocks. Whereas the whole point of the exercise was to
> reduce noise by denoising per session rather than block.

Denoise_pca indeed tries to reduce the noise in the magnetometer data
by computing a set of balancing coefficients, which are used to
subtract a weighted combination of the signals measured at the
reference sensors from the signals measured at the magnetometer coils.
As such, it is assumed that the signals picked up by the references
reflect purely environmental noise. If there is sensor specific noise,
e.g. a jump in one of the references, the denoising algorithm will
actually inject noise into the data. I suspect that in some of the
blocks there is some unaccounted noise in your references, which both
deteriorates the results in the concatenated block case, and also
leads to suboptimal results when denoise_pca operates on data that
contains the 'noisy' block.

> Why is this? Am I doing something fundamentally wrong? I'm wondering
> because a colleague of mine has done an almost identical analysis
> step a while ago and she doesn't get problems with high variance
> noise components. I'm not sure whether the problem lies with
> append_data or denoise-pca, but I know that append_data has been
> changed recently, so this might be one possible source of the problem.

I don't think ft_appenddata would be the cause of this, because this
function only concatenates data structures.

As a diagnostic I would check the quality of the reference channel
data first, and see whether there are anomalies across blocks there.

Good luck,
Jan-Mathijs


Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From moratti at MED.UCM.ES  Mon Nov  8 09:17:42 2010
From: moratti at MED.UCM.ES (Stephan Moratti)
Date: Mon, 8 Nov 2010 09:17:42 +0100
Subject: ft_appenddata and denoise_pca causing problems
Message-ID: <MON.8.NOV.2010.091742.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Luisa & Jan-Mathijs

This sounds like a similar problem that I had with 4D data using the
implemented noise reduction algorithm that offers 4D. When there was a very
big noise (like the subject coughing or moving a lot), the noise reduction
resulted in noiser data. I guess this has to do with the global weights
calculation. My solution was to inspect the data if there were data traces
of exceptionally big noise, then I used the 4D tool "mute" where you can set
data traces to zero with a smoothing function for the edges. Doing so, after
noise reduction the data was fine! Maybe something like this can solve your
problem, although I am not sure if it is related to your problem.

Best,

Stephan

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jedmeltzer at YAHOO.COM  Mon Nov  8 18:11:35 2010
From: jedmeltzer at YAHOO.COM (Jed Meltzer)
Date: Mon, 8 Nov 2010 09:11:35 -0800
Subject: Postdoctoral position available in Toronto,
 Neurobiology of Language
In-Reply-To: <FIELDTRIP%201011050005315190.0923@NIC.SURFNET.NL>
Message-ID: <MON.8.NOV.2010.091135.0800.FIELDTRIP@NIC.SURFNET.NL>

A postdoctoral fellowship in neurobiology of language is available in the 
laboratory of Dr. Jed Meltzer, at the Rotman Research Institute, affiliated with 
the University of Toronto.  The fellow will engage in research related to both 
basic language processes and applications to diagnosis and treatment of 
post-stroke aphasia, progressive aphasia, traumatic brain injury, and other 
neurological disorders.  Candidates should have expertise and/or interest in 
some of the following topics:
 
-       - sentence and discourse level comprehension and production
-       - neurorehabilitation in stroke and dementia
-       - frequency domain analysis of EEG/MEG data
-       - multivariate pattern recognition analyses
-       - applications of computational linguistics to neuroscience
-       - quantitative analysis of naturalistic language samples
-       - functional connectivity in fMRI and MEG
 
The Rotman Institute is fully equipped for cognitive neuroscience research, with 
a 3T MRI, 151-channel CTF MEG, several EEG systems, and an excellent 
infrastructure for patient recruitment and testing.  We seek a candidate with 
excellent computational skills, academic knowledge of psycholinguistics, and a 
personal manner suitable for comfortable interactions with elderly patients with 
limited communication abilities.  Prior experience with neuroimaging is helpful 
but not an absolute must. 
 
Toronto is consistently ranked as one of the most livable cities in the world, 
as well as the most multicultural.  It is an excellent place to work for those 
interested in cross-linguistic research, as native speaker populations can be 
found for dozens of world languages. 
 
Applicants should have a recent Ph.D. or M.D. degree, and the potential for 
successfully obtaining external funding.  The postdoctoral position carries a 
term of 2 years and is potentially renewable.  Bursaries are in line with the 
fellowship scales of the Canadian Institutes of Health Research (CIHR) and 
include an allowance for travel and research expenses. A minimum of 80% of each 
fellow’s time will be devoted to research and related activities.
Start date is negotiable, but ideally in the spring of 2011.
 
To apply, please send a current CV and letter of interest to:
Jed Meltzer, Ph.D.
jmeltzer at rotman-baycrest.on.ca
 
Up to three letters of reference may be forwarded to the same address.  Meetings 
and interviews may be arranged at the upcoming Neurobiology of Language and 
Society for Neuroscience conferences in San Diego, although this is certainly 
not required.
 
For more information on the institute, see
 
http://www.rotman-baycrest.on.ca/
 
and for our lab specifically,
 
http://www.rotman-baycrest.on.ca/index.php?section=1093
 
 
 
Jed A. Meltzer
Neurorehabilitation Scientist
Rotman Research Institute - Baycrest Centre
3560 Bathurst Street
Toronto, Ontario, M6A 2E1,CANADA

P: 416 785-2500 x 2117
F: 416 785-2862
C: 647 522-2187
jmeltzer at rotman-baycrest.on.ca





---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101108/47a85f48/attachment-0001.htm>

From batrod at GMAIL.COM  Tue Nov  9 00:48:54 2010
From: batrod at GMAIL.COM (Rodolphe)
Date: Mon, 8 Nov 2010 17:48:54 -0600
Subject: Coherence reference channel for statistical analysis
Message-ID: <MON.8.NOV.2010.174854.0600.FIELDTRIP@NIC.SURFNET.NL>

Dear Fieldtrip users,

i take the liberty to ask again my question to you, as i still didnt find a
solution.
I used ft_connectivityanalysis fuction to get coherence values between every
channels.
I simply wonder how to select a reference channel to make statistical
analysis , like when you can select a reference channel to make a
Topographic plot on coherence values.

Thanks a lot for your help,

Rodolphe.

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101108/c0b6fe4f/attachment-0001.htm>

From sklein at BERKELEY.EDU  Tue Nov  9 10:17:35 2010
From: sklein at BERKELEY.EDU (Stanley Klein)
Date: Tue, 9 Nov 2010 01:17:35 -0800
Subject: Coherence reference channel for statistical analysis
In-Reply-To: <AANLkTim7R9MnaHo-rg2kybf=jVkFoy7JvSi-0TKgZuX_@mail.gmail.com>
Message-ID: <TUE.9.NOV.2010.011735.0800.>

Rodolphe, one interesting option for dealing with the EEG problem of
reference electrode for coherence is to use Laplacians ("current sources")
for each electrode. You may be interested in the pair of papers Winter, et
al. J Neuroscience Methods 166 (2007) and Srinivasan, et al. (Statistics in
Medicine, 26 2007) that my colleague Jian Ding did with Winter, Srinivasan
and Nunez.  They compare Laplacian to regular reference for coherence.

I would think that a good approach would be to do it with several types of
very different references and compare the differences in coherence.

I'm going to be giving a talk on coherence next week at the Neuroscience
meeting in San Diego. I'm going to advocate measuring coherence on
unfiltered data, but using VERY broad-bandwidth Hilbert pair wavelets, very
local in time for doing the coherence. I have several questions on this:
1) Does anyone know whether very broad bandwidth Hilbert pair wavelets have
been used before? In my mind the locality in time is a useful complement to
alternative approaches.

2) Does anyone know whether it has been shown that Morlet and other usual
wavelets are not very pretty when only 1 to 1.5 cycles are present. We use
what we call Cauchy wavelets.

3) Is there a good reference for the connection of cross-correlation to
unnormalized coherence?
Let me define what I mean:
  CC(e1, e2, del) = v(e1, t) v(e2,t-del)           (1)       (using Einstein
summation convention
  Coh(e1, e2, f, n) = V(e1, t,  f, n) V*(e2, t, f, n) , (2) Einstein again
implying sum on t.
where v is the raw EEG, V is the wavelet transform
  V(e, t, f, n) = v(e, t+del) * W(del, f, n),      (3)
where   W(t, f, n) = 1/(1+ i f t)^n               (4)  for complex, Cauchy
Hilbert pair wavelet
e1, e2 are the electrodes (unreferenced preferably with referencing to be
done at end)
t is t, and del is the time shift
f is the peak frequency of the wavelet
n specifies the bandwidth of the wavelet (sqrt(n) is the number of half
cycles)

The connection between CC and Coh would be:
   Coh(e1, e2, f, n) = CC(e1, e2, t+del) *W(del, f', n')   (5)
where  f' and n' are simply connected to f and n but I'm still playing with
this to validate it all.

I'm very interested in learning whether Eq. 5 connecting unnormalized
coherence to cross-correlation is familiar, especially with a pretty closed
form time domain expression for the kernel W(del,f',n') in Eq. 5. The SfN
meeting is soon, which is why I'm eager to learn whether Eq. 5 is well
known. Pretty Hilbert pair filters like W are rare, so I'd be somewhat
surprised if Eq. 5 is commonly used. But I'm new to this coherence business
so I wouldn't be super surprised.

I'd be interested in any feedback. I'll also be happy to meet with anyone
interested in coherence at the SfN meeting or at the preceding
satellite meeting on "Resting State" before SfN.
Stan

On Mon, Nov 8, 2010 at 3:48 PM, Rodolphe <batrod at gmail.com> wrote:

> Dear Fieldtrip users,
>
> i take the liberty to ask again my question to you, as i still didnt find a
> solution.
> I used ft_connectivityanalysis fuction to get coherence values between
> every channels.
> I simply wonder how to select a reference channel to make statistical
> analysis , like when you can select a reference channel to make a
> Topographic plot on coherence values.
>
> Thanks a lot for your help,
>
> Rodolphe.
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101109/4c0ca787/attachment-0001.htm>

From ivana.konvalinka at GMAIL.COM  Tue Nov  9 11:36:45 2010
From: ivana.konvalinka at GMAIL.COM (Ivana Konvalinka)
Date: Tue, 9 Nov 2010 11:36:45 +0100
Subject: Partial Directed Coherence
Message-ID: <TUE.9.NOV.2010.113645.0100.FIELDTRIP@NIC.SURFNET.NL>

Hello,

I was wondering if it would be possible to get more information on partial
directed coherence, using ft_connectivityanalysis. I've been trying to set
it up on the frequency data of pairs of EEG electrodes, by partialling out
motor evoked fields.

Hence, something like this:
cfg.method = 'pdc';
cfg.channelcmb = { pairs of electrodes here };
cfg.partchannel = { electrodes containing fourier spectra of motor events };

pdc1 = ft_connectivityanalysis(cfg, freqs);

I get the following error: "reference to non-existent field 'transfer'".

Is there any more documentation on this method in fieldtrip?

Thanks in advance!

Ivana


--
Ivana Konvalinka
PhD Student
Interacting Minds Group
Center of Functionally Integrative Neuroscience
University of Aarhus
Denmark

http://www.interacting-minds.net
http://www.cfin.au.dk

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101109/8a01911e/attachment-0001.htm>

From jan.schoffelen at DONDERS.RU.NL  Tue Nov  9 11:54:56 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Tue, 9 Nov 2010 11:54:56 +0100
Subject: Partial Directed Coherence
In-Reply-To: <AANLkTi=LYNAUGzQw1PZn_rWO8p-A5d2e+CibxPTy3w4b@mail.gmail.com>
Message-ID: <TUE.9.NOV.2010.115456.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Ivana,

There is not so much information on the fieldtrip wiki as of yet. But
I am working on it.
For the time being, perhaps you know that in order to compute partial
directed coherence, you need to first fit an autoregressive model to
your time domain data. This is necessary to obtain a thing which is
known as the spectral transfer function, from which PDC will be derived.
Therefore you need to do two things before you can call
ft_connectivityanalysis:

use ft_mvaranalysis to obtain the MVAR-model of your data.
use ft_freqanalysis (cfg.method = 'mvar') to obtain the spectral
transfer function.

Note that you do not need to specify partchannel when you will be
computing pdc; the idea is that by fitting a multivariate model to all
channels of interest, the 'partialisation' is achieved. At least
that's the theory...

I hope to find time to work on the documentation soon.

Best wishes,

Jan-Mathijs


On Nov 9, 2010, at 11:36 AM, Ivana Konvalinka wrote:

> Hello,
>
> I was wondering if it would be possible to get more information on
> partial directed coherence, using ft_connectivityanalysis. I've been
> trying to set it up on the frequency data of pairs of EEG
> electrodes, by partialling out motor evoked fields.
>
> Hence, something like this:
> cfg.method = 'pdc';
> cfg.channelcmb = { pairs of electrodes here };
> cfg.partchannel = { electrodes containing fourier spectra of motor
> events };
>
> pdc1 = ft_connectivityanalysis(cfg, freqs);
>
> I get the following error: "reference to non-existent field
> 'transfer'".
>
> Is there any more documentation on this method in fieldtrip?
>
> Thanks in advance!
>
> Ivana
>
>
> --
> Ivana Konvalinka
> PhD Student
> Interacting Minds Group
> Center of Functionally Integrative Neuroscience
> University of Aarhus
> Denmark
>
> http://www.interacting-minds.net
> http://www.cfin.au.dk
>
> --------------------------------------------------------------------------- You
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101109/0ffc937d/attachment-0001.htm>

From ivana.konvalinka at GMAIL.COM  Tue Nov  9 13:35:08 2010
From: ivana.konvalinka at GMAIL.COM (Ivana Konvalinka)
Date: Tue, 9 Nov 2010 13:35:08 +0100
Subject: Partial Directed Coherence
In-Reply-To: <59C5E4F5-F1E9-480A-AD91-6E0B7C02A1F2@donders.ru.nl>
Message-ID: <TUE.9.NOV.2010.133508.0100.FIELDTRIP@NIC.SURFNET.NL>

Thanks Jan-Mathijs, that makes sense.

One more question - is it possible to just do partial coherence in
fieldtrip?

Best wishes,

Ivana



On Tue, Nov 9, 2010 at 11:54 AM, jan-mathijs schoffelen <
jan.schoffelen at donders.ru.nl> wrote:

> Dear Ivana,
>
> There is not so much information on the fieldtrip wiki as of yet. But I am
> working on it.
> For the time being, perhaps you know that in order to compute partial
> directed coherence, you need to first fit an autoregressive model to your
> time domain data. This is necessary to obtain a thing which is known as the
> spectral transfer function, from which PDC will be derived.
> Therefore you need to do two things before you can call
> ft_connectivityanalysis:
>
> use ft_mvaranalysis to obtain the MVAR-model of your data.
> use ft_freqanalysis (cfg.method = 'mvar') to obtain the spectral transfer
> function.
>
> Note that you do not need to specify partchannel when you will be computing
> pdc; the idea is that by fitting a multivariate model to all channels of
> interest, the 'partialisation' is achieved. At least that's the theory...
>
> I hope to find time to work on the documentation soon.
>
> Best wishes,
>
> Jan-Mathijs
>
>
> On Nov 9, 2010, at 11:36 AM, Ivana Konvalinka wrote:
>
> Hello,
>
> I was wondering if it would be possible to get more information on partial
> directed coherence, using ft_connectivityanalysis. I've been trying to set
> it up on the frequency data of pairs of EEG electrodes, by partialling out
> motor evoked fields.
>
> Hence, something like this:
> cfg.method = 'pdc';
> cfg.channelcmb = { pairs of electrodes here };
> cfg.partchannel = { electrodes containing fourier spectra of motor events
> };
>
> pdc1 = ft_connectivityanalysis(cfg, freqs);
>
> I get the following error: "reference to non-existent field 'transfer'".
>
> Is there any more documentation on this method in fieldtrip?
>
> Thanks in advance!
>
> Ivana
>
>
> --
> Ivana Konvalinka
> PhD Student
> Interacting Minds Group
> Center of Functionally Integrative Neuroscience
> University of Aarhus
> Denmark
>
> http://www.interacting-minds.net
> http://www.cfin.au.dk
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>
>
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl
> Telephone: 0031-24-3614793
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>



--
Ivana Konvalinka
PhD Student
Interacting Minds Group
Center of Functionally Integrative Neuroscience
University of Aarhus
Denmark

http://www.interacting-minds.net
http://www.cfin.au.dk

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101109/a6eb1672/attachment-0001.htm>

From l.frei at PSY.GLA.AC.UK  Wed Nov 10 13:12:13 2010
From: l.frei at PSY.GLA.AC.UK (Luisa Frei)
Date: Wed, 10 Nov 2010 12:12:13 +0000
Subject: ft_appenddata and denoise_pca causing problems
In-Reply-To: <0DA2C32A-5511-42A3-A968-045B695B0311@donders.ru.nl>
Message-ID: <WED.10.NOV.2010.121213.0000.FIELDTRIP@NIC.SURFNET.NL>

Hi Jan-Mathijs,
thanks for the reply. I have now resorted to denoising per block,
which gets rid of most of the noise components (although there is
usually one left per session, which is nothing to worry about, I've
been told). I have also visually inspected the blocks for one session
to make sure there are no jumps left and reduced the threshold for
jump artifacts. However, this didn't make much of a difference at all.

We discussed this in our MEG group meeting and I found out that one
other person had had the same problem, whereas another colleague
didn't have this problem, but she had used the old version of
ft_append_data. We thought, that if this keeps happening, it might be
worth taking a look at ft_append_data, to make sure it handles 4D
reference channels correctly. For now however, I'm happy with the
solution I have.

Thanks,
Luisa

On 8 Nov 2010, at 08:07, jan-mathijs schoffelen wrote:

> Dear Luisa,
>
>>
>> Hi,
>> I'm sorry if this has been discussed before and if it has, could
>> you please direct me to the relevant emails? Thanks.
>>
> Don't worry. This has not yet been discussed here before, and it's
> an interesting issue. Yet, probably most people wouldn't know what
> you are talking about, because the function denoise_pca is not yet
> part of the FieldTrip release version ;o). At the moment, it's only
> the CCNi and the fcdc who have it available.
>
>> I am encountering a problem when using ft_appenddata and
>> denoise_pca. My MEG experiment  (4D) consists of 10 blocks per
>> session, for each of which I have a separate data set.
>>
>> During preprocessing (after artifact rejection), I concatenate
>> these data sets to find denoising weights per session using the
>> function denoise_pca for 4D (I do this on shorter 400 ms epochs to
>> save computational power). Afterwards, I apply these weights per
>> block, downsample the data and concatenate the resulting data
>> again in order to do an ICA per session to remove heart beat
>> artifacts. I downsample because I use longer epochs to do that
>> (1.5 sec).
>> However, when I do an ICA on the denoised and concatenated
>> session, I get lots of high variance noise components (first figure):
>> Trying to find the root of this, I went back and did this analysis
>> for one block only (denoising for one block, no concatenating) and
>> the result looks much better (second figure):
>> Then, as a test, I tried to concatenate two blocks, find the
>> weights for those two concatenated blocks, apply them to the
>> individual blocks, concatenate again and do the ICA on these two
>> blocks and I get this (last figure):
>> So, it seems like when denoising per session (the concatenated
>> blocks), I introduce noise when I apply the pca weights to the
>> individual blocks. Whereas the whole point of the exercise was to
>> reduce noise by denoising per session rather than block.
>
> Denoise_pca indeed tries to reduce the noise in the magnetometer
> data by computing a set of balancing coefficients, which are used
> to subtract a weighted combination of the signals measured at the
> reference sensors from the signals measured at the magnetometer
> coils. As such, it is assumed that the signals picked up by the
> references reflect purely environmental noise. If there is sensor
> specific noise, e.g. a jump in one of the references, the denoising
> algorithm will actually inject noise into the data. I suspect that
> in some of the blocks there is some unaccounted noise in your
> references, which both deteriorates the results in the concatenated
> block case, and also leads to suboptimal results when denoise_pca
> operates on data that contains the 'noisy' block.
>
>> Why is this? Am I doing something fundamentally wrong? I'm
>> wondering because a colleague of mine has done an almost identical
>> analysis step a while ago and she doesn't get problems with high
>> variance noise components. I'm not sure whether the problem lies
>> with append_data or denoise-pca, but I know that append_data has
>> been changed recently, so this might be one possible source of the
>> problem.
>
> I don't think ft_appenddata would be the cause of this, because
> this function only concatenates data structures.
>
> As a diagnostic I would check the quality of the reference channel
> data first, and see whether there are anomalies across blocks there.
>
> Good luck,
> Jan-Mathijs
>
>
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl
> Telephone: 0031-24-3614793
>
> ----------------------------------------------------------------------
> -----
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ----------------------------------------------------------------------
> -----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From batrod at GMAIL.COM  Wed Nov 10 19:08:58 2010
From: batrod at GMAIL.COM (Rodolphe Nenert)
Date: Wed, 10 Nov 2010 19:08:58 +0100
Subject: Coherence reference channel for statistical analysis
Message-ID: <WED.10.NOV.2010.190858.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Stanley, 

thanks for this very interesting point. Actually i cant go to SFN but my boss 
will, and i asked her to go to your talk!
Anyway, i was in fact looking for a practical way to select a reference channel 
with Fieldtrip function ft_freqstatistics.
The function connectivityanalysis calculated coherence between all possible 
channel-pair of electrodes. 
But i dont want to make statistical analysis on all possible pairs, so i was 
looking for a cfg parameter in order to select a ref.
Actually, i copied the the part of the Topographic plot that does that, by 
searching the name of the specified ref electrode in all pairs and then redraw 
the matrix with only concerned pairs.


 



On Tue, 9 Nov 2010 01:17:35 -0800, Stanley Klein <sklein at BERKELEY.EDU> 
wrote:

>Rodolphe, one interesting option for dealing with the EEG problem of
>reference electrode for coherence is to use Laplacians ("current sources")
>for each electrode. You may be interested in the pair of papers Winter, et
>al. J Neuroscience Methods 166 (2007) and Srinivasan, et al. (Statistics in
>Medicine, 26 2007) that my colleague Jian Ding did with Winter, Srinivasan
>and Nunez.  They compare Laplacian to regular reference for coherence.
>
>I would think that a good approach would be to do it with several types of
>very different references and compare the differences in coherence.
>
>I'm going to be giving a talk on coherence next week at the Neuroscience
>meeting in San Diego. I'm going to advocate measuring coherence on
>unfiltered data, but using VERY broad-bandwidth Hilbert pair wavelets, very
>local in time for doing the coherence. I have several questions on this:
>1) Does anyone know whether very broad bandwidth Hilbert pair wavelets 
have
>been used before? In my mind the locality in time is a useful complement to
>alternative approaches.
>
>2) Does anyone know whether it has been shown that Morlet and other usual
>wavelets are not very pretty when only 1 to 1.5 cycles are present. We use
>what we call Cauchy wavelets.
>
>3) Is there a good reference for the connection of cross-correlation to
>unnormalized coherence?
>Let me define what I mean:
>  CC(e1, e2, del) = v(e1, t) v(e2,t-del)           (1)       (using Einstein
>summation convention
>  Coh(e1, e2, f, n) = V(e1, t,  f, n) V*(e2, t, f, n) , (2) Einstein again
>implying sum on t.
>where v is the raw EEG, V is the wavelet transform
>  V(e, t, f, n) = v(e, t+del) * W(del, f, n),      (3)
>where   W(t, f, n) = 1/(1+ i f t)^n               (4)  for complex, Cauchy
>Hilbert pair wavelet
>e1, e2 are the electrodes (unreferenced preferably with referencing to be
>done at end)
>t is t, and del is the time shift
>f is the peak frequency of the wavelet
>n specifies the bandwidth of the wavelet (sqrt(n) is the number of half
>cycles)
>
>The connection between CC and Coh would be:
>   Coh(e1, e2, f, n) = CC(e1, e2, t+del) *W(del, f', n')   (5)
>where  f' and n' are simply connected to f and n but I'm still playing with
>this to validate it all.
>
>I'm very interested in learning whether Eq. 5 connecting unnormalized
>coherence to cross-correlation is familiar, especially with a pretty closed
>form time domain expression for the kernel W(del,f',n') in Eq. 5. The SfN
>meeting is soon, which is why I'm eager to learn whether Eq. 5 is well
>known. Pretty Hilbert pair filters like W are rare, so I'd be somewhat
>surprised if Eq. 5 is commonly used. But I'm new to this coherence business
>so I wouldn't be super surprised.
>
>I'd be interested in any feedback. I'll also be happy to meet with anyone
>interested in coherence at the SfN meeting or at the preceding
>satellite meeting on "Resting State" before SfN.
>Stan
>
>On Mon, Nov 8, 2010 at 3:48 PM, Rodolphe <batrod at gmail.com> wrote:
>
>> Dear Fieldtrip users,
>>
>> i take the liberty to ask again my question to you, as i still didnt find a
>> solution.
>> I used ft_connectivityanalysis fuction to get coherence values between
>> every channels.
>> I simply wonder how to select a reference channel to make statistical
>> analysis , like when you can select a reference channel to make a
>> Topographic plot on coherence values.
>>
>> Thanks a lot for your help,
>>
>> Rodolphe.
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the FieldTrip list. The aim of this list is to facilitate the discussion
>> between users of the FieldTrip toolbox, to share experiences
>> and to discuss new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>>
>
>---------------------------------------------------------------------------
>You are receiving this message because you are subscribed to
>the  FieldTrip list. The aim of this list is to facilitate the discussion
>between  users of the FieldTrip  toolbox, to share experiences
>and to discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>---------------------------------------------------------------------------
>

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From cerisa.stawowsky at ONLINE.DE  Tue Nov 16 17:03:13 2010
From: cerisa.stawowsky at ONLINE.DE (Cerisa Stawowsky)
Date: Tue, 16 Nov 2010 17:03:13 +0100
Subject: problems with artifact correction after ICA
Message-ID: <TUE.16.NOV.2010.170313.0100.FIELDTRIP@NIC.SURFNET.NL>

An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101116/74f22af8/attachment-0001.htm>
-------------- next part --------------

Dear Fieldtrip user,

I used for my EEG-Data ICA to detect eye blinks. I remove the bad components and get 'cleaned' trials.
After ICA I want to use artifact correction for muscle artifacts, with following inputs:

DataAfterICATest =

 label: {128x1 cell}
 fsample: 1000
 trial: {1x39 cell}
 time: {1x39 cell}

trl = DataAfterICATest.sampleinfo

sampleinfo: [39x2 double]


cfg=[];
cfg.trl = trl
cfg.artfctdef.muscle.trlpadding = 0.1
cfg.artfctdef.muscle.sgn = 'EEG'; % selection of valid channels
cfg.artfctdef.muscle.bpfreq = [110 140];
cfg.artfctdef.muscle.cutoff = 4; % default = 4
cfg = ft_artifact_muscle(cfg,DataAfterICATest); % automatic muscle activity rejection

I get following errors:

Error in ==> ft_fetch_data at 109
 count = count(begsample:endsample);

Error in ==> ft_artifact_zvalue at 163
 dat{trlop} = ft_fetch_data(data, 'header', hdr, 'begsample', trl(trlop,1)-fltpadding, 'endsample',
 trl(trlop,2)+fltpadding, 'chanindx', sgnind, 'checkboundary', strcmp(cfg.continuous,'no')
Error in ==> ft_artifact_muscle at 152
 [tmpcfg, artifact] = ft_artifact_zvalue(tmpcfg, data);

Have somebody experience with artifact correction after ICA or with trials?


Best regards,

Cerisa Stawowsky


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

From jan.schoffelen at DONDERS.RU.NL  Wed Nov 17 09:49:56 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Wed, 17 Nov 2010 09:49:56 +0100
Subject: Partial Directed Coherence
In-Reply-To: <AANLkTinDwX=OYA=g8A-oqne4Dh7jXTuTLMsXEWwSPVuC@mail.gmail.com>
Message-ID: <WED.17.NOV.2010.094956.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Ivana,

Yes, it is possible to compute partial coherence. As already
mentioned, I am working on the documentation, but if you are bold
enough to give it a try you may want to look into the code of
ft_connectivityanalysis. What is needed for sure is a field
cfg.partchannel, containing the channel(s) which will be partialized
out. Probably things will work out of the box when the input to
ft_connectivityanalysis as obtained with ft_freqanalysis was generated
with cfg.output = 'fourier'.

Best wishes,

Jan-Mathijs


On Nov 9, 2010, at 1:35 PM, Ivana Konvalinka wrote:

> Thanks Jan-Mathijs, that makes sense.
>
> One more question - is it possible to just do partial coherence in
> fieldtrip?
>
> Best wishes,
>
> Ivana
>
>
>
> On Tue, Nov 9, 2010 at 11:54 AM, jan-mathijs schoffelen <jan.schoffelen at donders.ru.nl
> > wrote:
> Dear Ivana,
>
> There is not so much information on the fieldtrip wiki as of yet.
> But I am working on it.
> For the time being, perhaps you know that in order to compute
> partial directed coherence, you need to first fit an autoregressive
> model to your time domain data. This is necessary to obtain a thing
> which is known as the spectral transfer function, from which PDC
> will be derived.
> Therefore you need to do two things before you can call
> ft_connectivityanalysis:
>
> use ft_mvaranalysis to obtain the MVAR-model of your data.
> use ft_freqanalysis (cfg.method = 'mvar') to obtain the spectral
> transfer function.
>
> Note that you do not need to specify partchannel when you will be
> computing pdc; the idea is that by fitting a multivariate model to
> all channels of interest, the 'partialisation' is achieved. At least
> that's the theory...
>
> I hope to find time to work on the documentation soon.
>
> Best wishes,
>
> Jan-Mathijs
>
>
> On Nov 9, 2010, at 11:36 AM, Ivana Konvalinka wrote:
>
>> Hello,
>>
>> I was wondering if it would be possible to get more information on
>> partial directed coherence, using ft_connectivityanalysis. I've
>> been trying to set it up on the frequency data of pairs of EEG
>> electrodes, by partialling out motor evoked fields.
>>
>> Hence, something like this:
>> cfg.method = 'pdc';
>> cfg.channelcmb = { pairs of electrodes here };
>> cfg.partchannel = { electrodes containing fourier spectra of motor
>> events };
>>
>> pdc1 = ft_connectivityanalysis(cfg, freqs);
>>
>> I get the following error: "reference to non-existent field
>> 'transfer'".
>>
>> Is there any more documentation on this method in fieldtrip?
>>
>> Thanks in advance!
>>
>> Ivana
>>
>>
>> --
>> Ivana Konvalinka
>> PhD Student
>> Interacting Minds Group
>> Center of Functionally Integrative Neuroscience
>> University of Aarhus
>> Denmark
>>
>> http://www.interacting-minds.net
>> http://www.cfin.au.dk
>>
>> --------------------------------------------------------------------------- You
>>  are receiving this message because you are subscribed to
>> the FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between users of the FieldTrip toolbox, to share experiences
>> and to discuss new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>>
>
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl
> Telephone: 0031-24-3614793
>
> --------------------------------------------------------------------------- You
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>
>
>
>
> --
> Ivana Konvalinka
> PhD Student
> Interacting Minds Group
> Center of Functionally Integrative Neuroscience
> University of Aarhus
> Denmark
>
> http://www.interacting-minds.net
> http://www.cfin.au.dk
>
> --------------------------------------------------------------------------- You
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101117/bdcedefc/attachment-0001.htm>

From jan.schoffelen at DONDERS.RU.NL  Wed Nov 17 09:53:42 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Wed, 17 Nov 2010 09:53:42 +0100
Subject: ft_appenddata and denoise_pca causing problems
In-Reply-To: <B5E85D60-9325-4CF5-A90A-843445C968EC@psy.gla.ac.uk>
Message-ID: <WED.17.NOV.2010.095342.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi Luisa,

When discussing your problem with Joachim, he also mentioned the
ft_appenddata issue. I'd find it really strange if a change in
ft_appenddata would cause your problems. As such, ft_appenddata does
not make a distinction between different types of MEG-channels
(references or magnetometers). One way to check whether ft_appenddata
is the bad guy would be to let your colleague without the problems run
with a (recommended) recent version of fieldtrip.

Best,

Jan-Mathijs


On Nov 10, 2010, at 1:12 PM, Luisa Frei wrote:

> Hi Jan-Mathijs,
> thanks for the reply. I have now resorted to denoising per block,
> which gets rid of most of the noise components (although there is
> usually one left per session, which is nothing to worry about, I've
> been told). I have also visually inspected the blocks for one
> session to make sure there are no jumps left and reduced the
> threshold for jump artifacts. However, this didn't make much of a
> difference at all.
>
> We discussed this in our MEG group meeting and I found out that one
> other person had had the same problem, whereas another colleague
> didn't have this problem, but she had used the old version of
> ft_append_data. We thought, that if this keeps happening, it might
> be worth taking a look at ft_append_data, to make sure it handles 4D
> reference channels correctly. For now however, I'm happy with the
> solution I have.
>
> Thanks,
> Luisa
>
> On 8 Nov 2010, at 08:07, jan-mathijs schoffelen wrote:
>
>> Dear Luisa,
>>
>>>
>>> Hi,
>>> I'm sorry if this has been discussed before and if it has, could
>>> you please direct me to the relevant emails? Thanks.
>>>
>> Don't worry. This has not yet been discussed here before, and it's
>> an interesting issue. Yet, probably most people wouldn't know what
>> you are talking about, because the function denoise_pca is not yet
>> part of the FieldTrip release version ;o). At the moment, it's only
>> the CCNi and the fcdc who have it available.
>>
>>> I am encountering a problem when using ft_appenddata and
>>> denoise_pca. My MEG experiment  (4D) consists of 10 blocks per
>>> session, for each of which I have a separate data set.
>>>
>>> During preprocessing (after artifact rejection), I concatenate
>>> these data sets to find denoising weights per session using the
>>> function denoise_pca for 4D (I do this on shorter 400 ms epochs to
>>> save computational power). Afterwards, I apply these weights per
>>> block, downsample the data and concatenate the resulting data
>>> again in order to do an ICA per session to remove heart beat
>>> artifacts. I downsample because I use longer epochs to do that
>>> (1.5 sec).
>>> However, when I do an ICA on the denoised and concatenated
>>> session, I get lots of high variance noise components (first
>>> figure):
>>> Trying to find the root of this, I went back and did this analysis
>>> for one block only (denoising for one block, no concatenating) and
>>> the result looks much better (second figure):
>>> Then, as a test, I tried to concatenate two blocks, find the
>>> weights for those two concatenated blocks, apply them to the
>>> individual blocks, concatenate again and do the ICA on these two
>>> blocks and I get this (last figure):
>>> So, it seems like when denoising per session (the concatenated
>>> blocks), I introduce noise when I apply the pca weights to the
>>> individual blocks. Whereas the whole point of the exercise was to
>>> reduce noise by denoising per session rather than block.
>>
>> Denoise_pca indeed tries to reduce the noise in the magnetometer
>> data by computing a set of balancing coefficients, which are used
>> to subtract a weighted combination of the signals measured at the
>> reference sensors from the signals measured at the magnetometer
>> coils. As such, it is assumed that the signals picked up by the
>> references reflect purely environmental noise. If there is sensor
>> specific noise, e.g. a jump in one of the references, the denoising
>> algorithm will actually inject noise into the data. I suspect that
>> in some of the blocks there is some unaccounted noise in your
>> references, which both deteriorates the results in the concatenated
>> block case, and also leads to suboptimal results when denoise_pca
>> operates on data that contains the 'noisy' block.
>>
>>> Why is this? Am I doing something fundamentally wrong? I'm
>>> wondering because a colleague of mine has done an almost identical
>>> analysis step a while ago and she doesn't get problems with high
>>> variance noise components. I'm not sure whether the problem lies
>>> with append_data or denoise-pca, but I know that append_data has
>>> been changed recently, so this might be one possible source of the
>>> problem.
>>
>> I don't think ft_appenddata would be the cause of this, because
>> this function only concatenates data structures.
>>
>> As a diagnostic I would check the quality of the reference channel
>> data first, and see whether there are anomalies across blocks there.
>>
>> Good luck,
>> Jan-Mathijs
>>
>>
>> Dr. J.M. (Jan-Mathijs) Schoffelen
>> Donders Institute for Brain, Cognition and Behaviour,
>> Centre for Cognitive Neuroimaging,
>> Radboud University Nijmegen, The Netherlands
>> J.Schoffelen at donders.ru.nl
>> Telephone: 0031-24-3614793
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jan.schoffelen at DONDERS.RU.NL  Wed Nov 17 09:56:35 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Wed, 17 Nov 2010 09:56:35 +0100
Subject: Coherence reference channel for statistical analysis
In-Reply-To: <LISTSERV%201011101908587050.7C78@NIC.SURFNET.NL>
Message-ID: <WED.17.NOV.2010.095635.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Rodolphe,

If you have good a priori reasons to only do statistics on a subset of
channel pairs, you may want to constrain ft_connectivityanalysis into
not computing the full NxN coherence matrix. This is possible when you
provide ft_connecitivityanalysis with a field cfg.channelcmb,
specifying the combinations which you would like to compute. Some more
information can be found also in ft_channelcombination. To make it
work smoothly, it is optimal to provide ft_connecitvityanalysis with a
frequency structure containing fourier coefficients
(cfg.output='fourier' prior to calling ft_freqanalysis).

Best

JM


On Nov 10, 2010, at 7:08 PM, Rodolphe Nenert wrote:

> Dear Stanley,
>
> thanks for this very interesting point. Actually i cant go to SFN
> but my boss
> will, and i asked her to go to your talk!
> Anyway, i was in fact looking for a practical way to select a
> reference channel
> with Fieldtrip function ft_freqstatistics.
> The function connectivityanalysis calculated coherence between all
> possible
> channel-pair of electrodes.
> But i dont want to make statistical analysis on all possible pairs,
> so i was
> looking for a cfg parameter in order to select a ref.
> Actually, i copied the the part of the Topographic plot that does
> that, by
> searching the name of the specified ref electrode in all pairs and
> then redraw
> the matrix with only concerned pairs.
>
>
>
>
>
>
> On Tue, 9 Nov 2010 01:17:35 -0800, Stanley Klein <sklein at BERKELEY.EDU>
> wrote:
>
>> Rodolphe, one interesting option for dealing with the EEG problem of
>> reference electrode for coherence is to use Laplacians ("current
>> sources")
>> for each electrode. You may be interested in the pair of papers
>> Winter, et
>> al. J Neuroscience Methods 166 (2007) and Srinivasan, et al.
>> (Statistics in
>> Medicine, 26 2007) that my colleague Jian Ding did with Winter,
>> Srinivasan
>> and Nunez.  They compare Laplacian to regular reference for
>> coherence.
>>
>> I would think that a good approach would be to do it with several
>> types of
>> very different references and compare the differences in coherence.
>>
>> I'm going to be giving a talk on coherence next week at the
>> Neuroscience
>> meeting in San Diego. I'm going to advocate measuring coherence on
>> unfiltered data, but using VERY broad-bandwidth Hilbert pair
>> wavelets, very
>> local in time for doing the coherence. I have several questions on
>> this:
>> 1) Does anyone know whether very broad bandwidth Hilbert pair
>> wavelets
> have
>> been used before? In my mind the locality in time is a useful
>> complement to
>> alternative approaches.
>>
>> 2) Does anyone know whether it has been shown that Morlet and other
>> usual
>> wavelets are not very pretty when only 1 to 1.5 cycles are present.
>> We use
>> what we call Cauchy wavelets.
>>
>> 3) Is there a good reference for the connection of cross-
>> correlation to
>> unnormalized coherence?
>> Let me define what I mean:
>> CC(e1, e2, del) = v(e1, t) v(e2,t-del)           (1)       (using
>> Einstein
>> summation convention
>> Coh(e1, e2, f, n) = V(e1, t,  f, n) V*(e2, t, f, n) , (2) Einstein
>> again
>> implying sum on t.
>> where v is the raw EEG, V is the wavelet transform
>> V(e, t, f, n) = v(e, t+del) * W(del, f, n),      (3)
>> where   W(t, f, n) = 1/(1+ i f t)^n               (4)  for complex,
>> Cauchy
>> Hilbert pair wavelet
>> e1, e2 are the electrodes (unreferenced preferably with referencing
>> to be
>> done at end)
>> t is t, and del is the time shift
>> f is the peak frequency of the wavelet
>> n specifies the bandwidth of the wavelet (sqrt(n) is the number of
>> half
>> cycles)
>>
>> The connection between CC and Coh would be:
>>  Coh(e1, e2, f, n) = CC(e1, e2, t+del) *W(del, f', n')   (5)
>> where  f' and n' are simply connected to f and n but I'm still
>> playing with
>> this to validate it all.
>>
>> I'm very interested in learning whether Eq. 5 connecting unnormalized
>> coherence to cross-correlation is familiar, especially with a
>> pretty closed
>> form time domain expression for the kernel W(del,f',n') in Eq. 5.
>> The SfN
>> meeting is soon, which is why I'm eager to learn whether Eq. 5 is
>> well
>> known. Pretty Hilbert pair filters like W are rare, so I'd be
>> somewhat
>> surprised if Eq. 5 is commonly used. But I'm new to this coherence
>> business
>> so I wouldn't be super surprised.
>>
>> I'd be interested in any feedback. I'll also be happy to meet with
>> anyone
>> interested in coherence at the SfN meeting or at the preceding
>> satellite meeting on "Resting State" before SfN.
>> Stan
>>
>> On Mon, Nov 8, 2010 at 3:48 PM, Rodolphe <batrod at gmail.com> wrote:
>>
>>> Dear Fieldtrip users,
>>>
>>> i take the liberty to ask again my question to you, as i still
>>> didnt find a
>>> solution.
>>> I used ft_connectivityanalysis fuction to get coherence values
>>> between
>>> every channels.
>>> I simply wonder how to select a reference channel to make
>>> statistical
>>> analysis , like when you can select a reference channel to make a
>>> Topographic plot on coherence values.
>>>
>>> Thanks a lot for your help,
>>>
>>> Rodolphe.
>>>
>>> ---------------------------------------------------------------------------
>>> You are receiving this message because you are subscribed to
>>> the FieldTrip list. The aim of this list is to facilitate the
>>> discussion
>>> between users of the FieldTrip toolbox, to share experiences
>>> and to discuss new ideas for MEG and EEG analysis.
>>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>>> and http://www.ru.nl/neuroimaging/fieldtrip.
>>> ---------------------------------------------------------------------------
>>>
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>>
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From jan.schoffelen at DONDERS.RU.NL  Wed Nov 17 15:52:06 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Wed, 17 Nov 2010 15:52:06 +0100
Subject: ft_denoise_pca
Message-ID: <WED.17.NOV.2010.155206.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear all,

I just added a new function to the svn-repository, making it available
in the daily download as of tonight. This function is called
ft_denoise_pca and deals with the denoising of MEG data based on
concurrent measurements on reference sensors. The algorithm is
inspired by the denoising technique applied in the 4D neuroimaging
software, but can be applied whenever there are reference channel
measurements available. I allows for the computation (and application)
of balancing weights by regressing specified reference channels out of
the MEG data. There have been some recent threads on this discussion
list about this issue.

For those interested in using it: happy computing.

For those already using it: please revert to using the new version
which comes with your regular updates of fieldtrip. This version is
also not dependent anymore on the bunch of cellfunctions, because I
copied them as subfunctions into the main body of the code for the
time being.

Best wishes,

Jan-Mathijs

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From sander at MPIB-BERLIN.MPG.DE  Thu Nov 18 15:48:43 2010
From: sander at MPIB-BERLIN.MPG.DE (Sander, Myriam)
Date: Thu, 18 Nov 2010 15:48:43 +0100
Subject: Testing for an interaction effect with more than 1 ivar using
 depsamplesF
Message-ID: <THU.18.NOV.2010.154843.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Fieldtrip-Users, 

 

I would like to test for an interaction effect in a within-subject
experiment. I know there was a similar question by Tzvetan Popov this
year, but I did not find an answer to his question in the archives, so I
would like to ask this again. 
  

 I have 5 subjects and 2 within-factors, one with 2 levels and one with
3 levels. 

I specified the design matrix as

 

1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5

1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2

1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3

 

clusterstatcfg.ivar   = [2,3];

clusterstatcfg.uvar   = 1;

 

I want to use freqstatistics with depsamplesF using montecarlo / cluster
as correction method, but I get the following error: 

Error using ==> statfun_depsamplesF at 110

Invalid specification of the design array.

 

The problem seems to me that depsamplesF only allows for 1 ivar, but not
two - is that right? 

 

Is there a way how to test interaction effects in this way? Or is it
necessary to first take the difference between the 2 levels of the first
factors and then only test for the effect of the second factor? 

 

Thanks a lot for your help, 

Myriam 

 

______________________________________

 

Myriam Sander, Dipl.-Psych.

Predoctoral Research Fellow

Center for Lifespan Psychology

Max Planck Institute for Human Development

Lentzeallee 94

14195 Berlin Germany

 

Office Phone: (49) 30-82406-414

Fax: (49) 30-8249939

 

sander at mpib-berlin.mpg.de <mailto:sander at mpib-berlin.mpg.de> 

______________________________________

 


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101118/a7b05c2e/attachment-0001.htm>

From chavera at GMX.DE  Thu Nov 18 18:01:56 2010
From: chavera at GMX.DE (Saskia Helbling)
Date: Thu, 18 Nov 2010 18:01:56 +0100
Subject: Testing for an interaction effect with more than 1 ivar using
 depsamplesF
In-Reply-To: <82EE999347EBF142A8D78EF16FB83D8D01EDBD56@MPIBMAIL01.mpib-berlin.mpg.de>
Message-ID: <THU.18.NOV.2010.180156.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Myriam,

earlier threads about 2-way ANOVA can be found here:
https://listserv.surfnet.nl/scripts/wa.cgi?A2=ind1009&L=FIELDTRIP&P=R11455
or here:
https://listserv.surfnet.nl/scripts/wa.cgi?A2=ind0911&L=FIELDTRIP&P=R2726

You are right, depsamplesF accepts only one independent variable and therefor only works for a 1-way ANOVA.

It is not possible to construct an exact permutation test for an interaction, as you'd have to restrict permutations within the levels of the main effects - which leaves you with no exchangeable units you may permute.

There are approximate tests, though. The paper of Anderson et al was posted here already, but since I found it very useful, I cite it again: Anderson MJ and Ter Braak CJF, "PERMUTATION TESTS FOR MULTI-FACTORIAL ANALYSIS OF VARIANCE", J Statistical Computation and Simulation, 2003.

The easiest way to do an approximate test mentioned there, would be Manly's approach of unrestricted (not limited to occur only within levels) permutations of the raw data (raw meaning you do not subtract any cell means). There are more sophisticated approaches, as restricted permutation of residuals, with higher power and a more intuitive justification. However, unrestricted permutations are easiest to implement.

You can start with the statfun_depsamplesF function, which would give you  a suitable data structure (with unrestricted permutations), and feed this data into your ANOVA model (I used the resampling_statistical_toolkit of Delorme). You'll have to adapt the critical values, dfs & the probabilities with respect to the interaction effect. Then you just test your found interaction effect against your "interaction effect distribution" gained by the permutations - as usually.

Approximate tests haven't been discussed at this list, as far as I know, I'd highly appreciate any objections/comments on this topic.

Thanks in advance, best Saskia



--

Saskia Helbling
Institute of Medical Psychology
Goethe University
Frankfurt am Main, Germany
Tel. +49-69-63015661
Fax. +49-69-63017606



-------- Original-Nachricht --------
> Datum: Thu, 18 Nov 2010 15:48:43 +0100
> Von: "Sander, Myriam" <sander at MPIB-BERLIN.MPG.DE>
> An: FIELDTRIP at NIC.SURFNET.NL
> Betreff: [FIELDTRIP] Testing for an interaction effect with more than 1 ivar using depsamplesF

> Dear Fieldtrip-Users,
>
>
>
> I would like to test for an interaction effect in a within-subject
> experiment. I know there was a similar question by Tzvetan Popov this
> year, but I did not find an answer to his question in the archives, so I
> would like to ask this again.
>
>
>  I have 5 subjects and 2 within-factors, one with 2 levels and one with
> 3 levels.
>
> I specified the design matrix as
>
>
>
> 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5 1 2 3 4 5
>
> 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2
>
> 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3
>
>
>
> clusterstatcfg.ivar   = [2,3];
>
> clusterstatcfg.uvar   = 1;
>
>
>
> I want to use freqstatistics with depsamplesF using montecarlo / cluster
> as correction method, but I get the following error:
>
> Error using ==> statfun_depsamplesF at 110
>
> Invalid specification of the design array.
>
>
>
> The problem seems to me that depsamplesF only allows for 1 ivar, but not
> two - is that right?
>
>
>
> Is there a way how to test interaction effects in this way? Or is it
> necessary to first take the difference between the 2 levels of the first
> factors and then only test for the effect of the second factor?
>
>
>
> Thanks a lot for your help,
>
> Myriam
>
>
>
> ______________________________________
>
>
>
> Myriam Sander, Dipl.-Psych.
>
> Predoctoral Research Fellow
>
> Center for Lifespan Psychology
>
> Max Planck Institute for Human Development
>
> Lentzeallee 94
>
> 14195 Berlin Germany
>
>
>
> Office Phone: (49) 30-82406-414
>
> Fax: (49) 30-8249939
>
>
>
> sander at mpib-berlin.mpg.de <mailto:sander at mpib-berlin.mpg.de>
>
> ______________________________________
>
>
>
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From manish.saggar at GMAIL.COM  Sat Nov 20 08:20:36 2010
From: manish.saggar at GMAIL.COM (Manish Saggar)
Date: Sat, 20 Nov 2010 01:20:36 -0600
Subject: avgoverfreq is good or bad?
Message-ID: <SAT.20.NOV.2010.012036.0600.FIELDTRIP@NIC.SURFNET.NL>

Dear all,

I have spatio-spectral EEG data (no temporal information) from two
groups. Group A was tested three times (t1,t2,t3) during a treatment
and group B (control group) was also tested at the same three time
points. Now I simply want to know which <channel, frequency> pairs
differ for each group separately. Thus, I ran depsamplesF test
(cluster with montecarlo) for each group for a large frequency range,
say 0.5 - 100Hz, cfg.avgoverfreq = 'no'.  I then used Bonferroni
correction (for two tests) and plotted the clusters using multiplotTFR
with 'mask' as zstat parameter. The clusters of <ch, freq> I get are
mostly in 15-40Hz range and usually there is only one big cluster.

Now my question is - by running over a huge range of frequency (using
no averaging over freq), did I lower the power for low freq bands
(like delta, theta, and alpha)? Should I rather run these tests
separately for low freq bands (like delta, theta, and alpha) with
avgoverfreq='yes'. And may be another test for high frequencies like
14-100 Hz with no averaging over frequencies.

The reason I was running one test for all frequencies was to avoid
multiple tests and hence avoiding more stringent Bonferroni
correction.

Thanks,
m-



Manish Saggar,
Doctoral Candidate,
Department of Computer Science,
The University of Texas at Austin,
Web: http://www.cs.utexas.edu/~mishu/
Email: mishu at cs.utexas.edu

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From e.maris at DONDERS.RU.NL  Sat Nov 20 13:41:20 2010
From: e.maris at DONDERS.RU.NL (Eric Maris)
Date: Sat, 20 Nov 2010 13:41:20 +0100
Subject: avgoverfreq is good or bad?
In-Reply-To: <AANLkTinT9Jh+8PWVeX6a38vq6Qb=GR+Co9Lf7pj3i4TB@mail.gmail.com>
Message-ID: <SAT.20.NOV.2010.134120.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Manish,


As a rule, whenever you incorporate valid prior information in your
statistical analysis, you will increase sensitivity. For instance, assume
that there physiological reasons why effects should always occur in a number
of discrete frequency bands; [0.5,1.5] (delta), [4,6] (theta), [8,12]
(alpha), [13,30] (beta), and [31,80] (gamma). Then, you will increase power
by (1) estimating the average power in these frequency bands (using
multitaper estimation with the appropriate spectral smoothing), and (2)
performing a cluster-based permutation test on the resulting
(channel,frequency bin)-data. Without frequency smoothing in the a priori
defined frequency intervals sensitivity will be lower, assumed the intervals
are valid of course. You can further increase sensitivity if you know a
priori that effects will only occur in one of the frequency bands, but that
does not seem to be the case for you.

Good luck,

Eric Maris


dr. Eric Maris
Donders Institute for Brain, Cognition and Behavior
Center for Cognition and F.C. Donders Center for Cognitive Neuroimaging
Radboud University
P.O. Box 9104
6500 HE Nijmegen
The Netherlands
T:+31 24 3612651
Mobile: 06 39584581
F:+31 24 3616066
E: e.maris at donders.ru.nl







> -----Original Message-----
> From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On
> Behalf Of Manish Saggar
> Sent: zaterdag 20 november 2010 8:21
> To: FIELDTRIP at NIC.SURFNET.NL
> Subject: [FIELDTRIP] avgoverfreq is good or bad?
>
> Dear all,
>
> I have spatio-spectral EEG data (no temporal information) from two
> groups. Group A was tested three times (t1,t2,t3) during a treatment
> and group B (control group) was also tested at the same three time
> points. Now I simply want to know which <channel, frequency> pairs
> differ for each group separately. Thus, I ran depsamplesF test
> (cluster with montecarlo) for each group for a large frequency range,
> say 0.5 - 100Hz, cfg.avgoverfreq = 'no'.  I then used Bonferroni
> correction (for two tests) and plotted the clusters using multiplotTFR
> with 'mask' as zstat parameter. The clusters of <ch, freq> I get are
> mostly in 15-40Hz range and usually there is only one big cluster.
>
> Now my question is - by running over a huge range of frequency (using
> no averaging over freq), did I lower the power for low freq bands
> (like delta, theta, and alpha)? Should I rather run these tests
> separately for low freq bands (like delta, theta, and alpha) with
> avgoverfreq='yes'. And may be another test for high frequencies like
> 14-100 Hz with no averaging over frequencies.
>
> The reason I was running one test for all frequencies was to avoid
> multiple tests and hence avoiding more stringent Bonferroni
> correction.
>
> Thanks,
> m-
>
>
>
> Manish Saggar,
> Doctoral Candidate,
> Department of Computer Science,
> The University of Texas at Austin,
> Web: http://www.cs.utexas.edu/~mishu/
> Email: mishu at cs.utexas.edu
>
> -----------------------------------------------------------------------
> ----
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the
> discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> -----------------------------------------------------------------------
> ----

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From paul_c at GMX.DE  Mon Nov 22 07:28:21 2010
From: paul_c at GMX.DE (Paul Czienskowski)
Date: Mon, 22 Nov 2010 07:28:21 +0100
Subject: Stability of ft_dipolefitting
Message-ID: <MON.22.NOV.2010.072821.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear all,

as a pretest for my diploma thesis, which deals with the source
localization in EEG, I tried to generate some simulated EEG Data and fit
them both with the BEM model I generated them with and a BEM model I
generated from the icbm152 brain. The set of electrodes was generated
from the  10-20-system's instruction. I found that the  'real' brain
model fitted the data quite good, but the fitting with the other model
failed completely for it 'found' the dipole position on the way other
hemisphere pointing inwards instead of in the vertex direction. Since
this seemed quite  strange to us we decided to fit the data with one of
our other real brain models. Even if the dipole was located in the right
hemisphere now the fit was quite poor for it located the dipole in the
brain stem or in the medulla oblongata rather than in the auditory
cortex where it was simulated. When I didn't let the fit perform the
scan on the grid but let it run on some initial position in the auditory
cortex the fit with one of the other models performed a bit better but
still with a too small moment and still ~5 cm away from our position.
I know I won't be able to perform a perfect fit with another model but
it should be better than this - at least I thought - for I think we'll
never have a perfect model of a head and thus we wouldn't be able to
perform any reasonable fit if it was that unstable. Has anyone any clue
which could have been my fault. I know it's not easy without the data
and even the figures but maybe there's anything you already see from my
approach which was completely wrong. Some basic data: As I told you
before I used a 10-20-electrode-system, my models had 4 layers with each
about  1000 vertices ([999,1004] to be accurate), generated from a spm8
segmentation with a script inspired by
http://fieldtrip.fcdonders.nl/example/create_bem_headmodel_for_eeg . I
generated the models with OpenMEEG. For the grid search I used the gray
matter from the spm8 segmentation and down sampled it to a 5 mm grid.

Thanks in advance,
Paul Czienskowski

--
Paul Czienskowski
Max Planck institute for human development
Lentzeallee 94
14195 Berlin

Björnsonstr. 25
12163 Berlin

Tel.: (+49)(0)30/221609359
Handy: (+49)(0)1788378772

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From ekanal at CMU.EDU  Mon Nov 22 17:48:52 2010
From: ekanal at CMU.EDU (Kanal Eliezer)
Date: Mon, 22 Nov 2010 11:48:52 -0500
Subject: ft_rejectvisual: different scales for magnet- and gradi-ometers?
Message-ID: <MON.22.NOV.2010.114852.0500.FIELDTRIP@NIC.SURFNET.NL>

Hello folks -

In using ft_rejectvisual, it seems that the magnetometer and gradiometer data is on a different scale. See this picture [1] for an example of this. The help for ft_rejectvisual suggests that I can scale the meg data differently than the eeg data, but doesn't list any way to scale different types of MEG data. Is there any way I can scale data based using a user function? For example, all channels ending with '1' are meg, '2' and '3' are grad, so I can use that. Also, I know I can view the data independently using the cfg.channel config option... I want to know if I can have it on a single screen. Thanks!

Elli Kanal

[1] http://www.andrew.cmu.edu/user/ekanal/ft_rejectvisual-mag-vs-grad.png


--------------------
Eliezer Kanal, Ph.D.
Postdoctoral Fellow
Center for the Neural Basis of Cognition
Carnegie Mellon University
4400 Fifth Ave, Suite 115
Pittsburgh PA 15213
P: 412-268-4115
F: 412-268-5060

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From michael.wibral at WEB.DE  Mon Nov 22 19:54:44 2010
From: michael.wibral at WEB.DE (Michael Wibral)
Date: Mon, 22 Nov 2010 19:54:44 +0100
Subject: Combining different MEG sensortypes
Message-ID: <MON.22.NOV.2010.195444.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Fieldtrip users (with a Neuromag system),

I have a question on how to combine the Information from the planar gradiometers and the magnetometers of a 306 channel Neurmag system best for beamformer weight computation and source time course reconstruction. Do you compute a complete leadfield mixing both types of gradiometers (i.e. you do an unweighted analysis)? Do you somehow weight the sensors for their different noise levels? Do you compute two sets of timecourses (one from grads, one from megnetometers)?
A related question: Do you update the leadfileds for projections that MAxfiltering does (like it should be done when using ICA)?

I am asking because it has been shown that the more sensors are available the better the time course reconstruction (a recent paper by Matthew Brookes). Hence it would be a pity to have to throw some of the information away.

Michael

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Michael Wibral.vcf
Type: text/x-vcard
Size: 628 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101122/db9a9cd3/attachment-0001.vcf>

From lauri at NEURO.HUT.FI  Tue Nov 23 08:24:52 2010
From: lauri at NEURO.HUT.FI (Lauri Parkkonen)
Date: Tue, 23 Nov 2010 09:24:52 +0200
Subject: Combining different MEG sensortypes
In-Reply-To: <893393094.122969.1290452084874.JavaMail.fmail@mwmweb053>
Message-ID: <TUE.23.NOV.2010.092452.0200.FIELDTRIP@NIC.SURFNET.NL>

Hello Michael,

At least for MNE and beamforming, the most common approach is to use
both magnetometers and planar gradiometers together in a single (mixed)
forward solution; however, weighting must be applied because the units
and numerical scales of the two sensor types are different. This
weighting is typically done by estimating the noise covariance matrix
and then using the reciprocals of the diagonal elements for each
channel. If obtaining the full noise covariance matrix is too
troublesome for some reason, the obvious shortcut is to just compute the
baseline noise RMS, i.e., the diagonal of the matrix, which is what the
multi-dipole modelling software (by Neuromag) does.

There is no localization or amplitude bias if you source model
SSS'ed/MaxFiltered data directly whereas -- as you pointed out -- such
bias does exist for ICA or otherwise projected data. The important
difference is that SSS includes complete models for all possible signal
patterns originating from the volumes inside and outside the sensor
array, and these subspaces are linearly independent. On the contrary, a
component/signal vector determined from the data (by ICA or PCA, for
example) generally has a non-vanishing projection on the brain signal
subspace and without knowing that subspace, there is no way to "undo"
the distortion of that part of the signal but one has to carry the
information about the projection all the way to the lead field.

You certainly know the following but for those who may wonder: After
MaxFiltering, one may still need to take into account the reduced number
of degrees of freedom in the regularisation in MNE and beamforming. For
example, dropping the lower N of the eigenvalues may not have the
desired effect as some of the retained eigenvalues may already be zero
in MaxFiltered data (while they would be small but non-zero for
non-filtered data).

Best regards,
Lauri

22.11.2010 20:54, Michael Wibral kirjoitti:
> Dear Fieldtrip users (with a Neuromag system),
>
> I have a question on how to combine the Information from the planar gradiometers and the magnetometers of a 306 channel Neurmag system best for beamformer weight computation and source time course reconstruction. Do you compute a complete leadfield mixing both types of gradiometers (i.e. you do an unweighted analysis)? Do you somehow weight the sensors for their different noise levels? Do you compute two sets of timecourses (one from grads, one from megnetometers)?
> A related question: Do you update the leadfileds for projections that MAxfiltering does (like it should be done when using ICA)?
>
> I am asking because it has been shown that the more sensors are available the better the time course reconstruction (a recent paper by Matthew Brookes). Hence it would be a pity to have to throw some of the information away.
>
> Michael
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE  Tue Nov 23 10:20:22 2010
From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann)
Date: Tue, 23 Nov 2010 10:20:22 +0100
Subject: paths to connectivity function
Message-ID: <TUE.23.NOV.2010.102022.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear fieldtrip developers,

 

I have just installed the newest version as outlined on your website
(addpath without genpath and calling fieldtripdefs, old paths removed).
I noticed that calling ft_connectivityanalysis with method "coh" now
results in the error

 

??? Undefined function or method 'univariate2bivariate' for input
arguments of type 'struct'.

 

It is overcome by manually adding the folder connectivity to the search
path. Maybe fieldtripdefs does not include the connectivity functions
correctly?

 

Best,

jan

 

Jan Hirschmann

MSc. Neuroscience

Insititute of Clinical Neuroscience and Medical Psychology

Heinrich Heine University Duesseldorf

Universitaetsstr.  1
40225  Duesseldorf

Tel: 0049 - (0)211 - 81 - 18076

 


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/5b9770aa/attachment-0001.htm>

From jan.schoffelen at DONDERS.RU.NL  Tue Nov 23 10:30:01 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Tue, 23 Nov 2010 10:30:01 +0100
Subject: paths to connectivity function
In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8B01DC8D02@Mail2-UKD.VMED.UKD>
Message-ID: <TUE.23.NOV.2010.103001.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Jan,

Thanks for letting us know. As far as I can see, the function  
fieldtripdefs tries to add the connectivity folder to the path (line  
112 of version 2017). Are you sure you are using the most recent  
fieldtripdefs function?

Best,

JM

On Nov 23, 2010, at 10:20 AM, Jan Hirschmann wrote:


> Dear fieldtrip developers,
>
> I have just installed the newest version as outlined on your website  
> (addpath without genpath and calling fieldtripdefs, old paths  
> removed). I noticed that calling ft_connectivityanalysis with method  
> “coh” now results in the error
>
> ??? Undefined function or method 'univariate2bivariate' for input  
> arguments of type ‘struct'.
>
> It is overcome by manually adding the folder connectivity to the  
> search path. Maybe fieldtripdefs does not include the connectivity  
> functions correctly?
>
> Best,
> jan
>
> Jan Hirschmann
> MSc. Neuroscience
> Insititute of Clinical Neuroscience and Medical Psychology
> Heinrich Heine University Duesseldorf
> Universitaetsstr.  1
> 40225  Duesseldorf
> Tel: 0049 - (0)211 - 81 - 18076
>
> --------------------------------------------------------------------------- You 
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the  
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/354d814d/attachment-0001.htm>

From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE  Tue Nov 23 10:34:17 2010
From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann)
Date: Tue, 23 Nov 2010 10:34:17 +0100
Subject: poor guys called Jan
Message-ID: <TUE.23.NOV.2010.103417.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi,

 

as I am on it, I might as well make another minor improvement
suggestion. Ft_freqstatistics asks the system whether the user is named
jan and if so, calls statistics_wrapperJM instead of statistics_wrapper.
For people named Jan this is inconvenient, as the JM function is
probably found nowhere but on Jan-Mathijs' computer, I guess. What about
all the other Jans? :-)

 

Best,

jan


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/6a17280e/attachment-0001.htm>

From michael.wibral at WEB.DE  Tue Nov 23 10:37:10 2010
From: michael.wibral at WEB.DE (Michael Wibral)
Date: Tue, 23 Nov 2010 10:37:10 +0100
Subject: Combining different MEG sensortypes
In-Reply-To: <4CEB6C44.6070109@neuro.hut.fi>
Message-ID: <TUE.23.NOV.2010.103710.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Lauri,

thank you very much for your reply that was indeed very helpful.

Michael

-----Ursprüngliche Nachricht-----
Von: "Lauri Parkkonen" <lauri at NEURO.HUT.FI>
Gesendet: Nov 23, 2010 8:24:52 AM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] Combining different MEG sensortypes

>Hello Michael,
>
>At least for MNE and beamforming, the most common approach is to use 
>both magnetometers and planar gradiometers together in a single (mixed) 
>forward solution; however, weighting must be applied because the units 
>and numerical scales of the two sensor types are different. This 
>weighting is typically done by estimating the noise covariance matrix 
>and then using the reciprocals of the diagonal elements for each 
>channel. If obtaining the full noise covariance matrix is too 
>troublesome for some reason, the obvious shortcut is to just compute the 
>baseline noise RMS, i.e., the diagonal of the matrix, which is what the 
>multi-dipole modelling software (by Neuromag) does.
>
>There is no localization or amplitude bias if you source model 
>SSS'ed/MaxFiltered data directly whereas -- as you pointed out -- such 
>bias does exist for ICA or otherwise projected data. The important 
>difference is that SSS includes complete models for all possible signal 
>patterns originating from the volumes inside and outside the sensor 
>array, and these subspaces are linearly independent. On the contrary, a 
>component/signal vector determined from the data (by ICA or PCA, for 
>example) generally has a non-vanishing projection on the brain signal 
>subspace and without knowing that subspace, there is no way to "undo" 
>the distortion of that part of the signal but one has to carry the 
>information about the projection all the way to the lead field.
>
>You certainly know the following but for those who may wonder: After 
>MaxFiltering, one may still need to take into account the reduced number 
>of degrees of freedom in the regularisation in MNE and beamforming. For 
>example, dropping the lower N of the eigenvalues may not have the 
>desired effect as some of the retained eigenvalues may already be zero 
>in MaxFiltered data (while they would be small but non-zero for 
>non-filtered data).
>
>Best regards,
>Lauri
>
>22.11.2010 20:54, Michael Wibral kirjoitti:
>> Dear Fieldtrip users (with a Neuromag system),
>>
>> I have a question on how to combine the Information from the planar gradiometers and the magnetometers of a 306 channel Neurmag system best for beamformer weight computation and source time course reconstruction. Do you compute a complete leadfield mixing both types of gradiometers (i.e. you do an unweighted analysis)? Do you somehow weight the sensors for their different noise levels? Do you compute two sets of timecourses (one from grads, one from megnetometers)?
>> A related question: Do you update the leadfileds for projections that MAxfiltering does (like it should be done when using ICA)?
>>
>> I am asking because it has been shown that the more sensors are available the better the time course reconstruction (a recent paper by Matthew Brookes). Hence it would be a pity to have to throw some of the information away.
>>
>> Michael
>>
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>
>---------------------------------------------------------------------------
>You are receiving this message because you are subscribed to
>the  FieldTrip list. The aim of this list is to facilitate the discussion
>between  users of the FieldTrip  toolbox, to share experiences
>and to discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Michael Wibral.vcf
Type: text/x-vcard
Size: 628 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/d4ac749d/attachment-0001.vcf>

From jan.schoffelen at DONDERS.RU.NL  Tue Nov 23 10:40:41 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Tue, 23 Nov 2010 10:40:41 +0100
Subject: poor guys called Jan
In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8B01DC8D12@Mail2-UKD.VMED.UKD>
Message-ID: <TUE.23.NOV.2010.104041.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Jan,

Oops. Yes, I sincerely apologize for this one. I thought I took it out  
already a while ago. I'll do it as we speak. Or would you prefer to  
have the statistics_wrapperJM? Then we can start our own little  
fieldtrip-twig ;o).

Cheers,

Jan-M


On Nov 23, 2010, at 10:34 AM, Jan Hirschmann wrote:

> Hi,
>
> as I am on it, I might as well make another minor improvement  
> suggestion. Ft_freqstatistics asks the system whether the user is  
> named jan and if so, calls statistics_wrapperJM instead of  
> statistics_wrapper. For people named Jan this is inconvenient, as  
> the JM function is probably found nowhere but on Jan-Mathijs’  
> computer, I guess. What about all the other Jans? J
>
> Best,
> jan
> --------------------------------------------------------------------------- You 
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the  
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/2976cb85/attachment-0001.htm>

From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE  Tue Nov 23 10:45:58 2010
From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann)
Date: Tue, 23 Nov 2010 10:45:58 +0100
Subject: AW: [FIELDTRIP] paths to connectivity function
In-Reply-To: A<50C33905-E76F-4927-AC34-9241B4B54FB3@donders.ru.nl>
Message-ID: <TUE.23.NOV.2010.104558.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Jan-Mathijs,

 

I think I am. According to Matlabs which function at least, and the code
you are relating to is at line 112 in my function, too.

 

Best,

jan

 

________________________________

Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im
Auftrag von jan-mathijs schoffelen
Gesendet: Dienstag, 23. November 2010 10:30
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] paths to connectivity function

 

Dear Jan,

 

Thanks for letting us know. As far as I can see, the function
fieldtripdefs tries to add the connectivity folder to the path (line 112
of version 2017). Are you sure you are using the most recent
fieldtripdefs function?

 

Best,

 

JM

 

On Nov 23, 2010, at 10:20 AM, Jan Hirschmann wrote:

 





Dear fieldtrip developers,

 

I have just installed the newest version as outlined on your website
(addpath without genpath and calling fieldtripdefs, old paths removed).
I noticed that calling ft_connectivityanalysis with method "coh" now
results in the error

 

??? Undefined function or method 'univariate2bivariate' for input
arguments of type 'struct'.

 

It is overcome by manually adding the folder connectivity to the search
path. Maybe fieldtripdefs does not include the connectivity functions
correctly?

 

Best,

jan

 

Jan Hirschmann

MSc. Neuroscience

Insititute of Clinical Neuroscience and Medical Psychology

Heinrich Heine University Duesseldorf

Universitaetsstr.  1
40225  Duesseldorf

Tel: 0049 - (0)211 - 81 - 18076

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---

 

Dr. J.M. (Jan-Mathijs) Schoffelen 

Donders Institute for Brain, Cognition and Behaviour, 
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands

J.Schoffelen at donders.ru.nl

Telephone: 0031-24-3614793

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/8755064e/attachment-0001.htm>

From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE  Tue Nov 23 11:05:52 2010
From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann)
Date: Tue, 23 Nov 2010 11:05:52 +0100
Subject: AW: [FIELDTRIP] poor guys called Jan
In-Reply-To: A<A700BB31-4C06-42BF-A4C4-B10FA56C8694@donders.ru.nl>
Message-ID: <TUE.23.NOV.2010.110552.0100.FIELDTRIP@NIC.SURFNET.NL>

No prob. Yes, I think the Jan-files must be the ones with all the fancy
new techniques the world is yet to marvel about. And some exclusive
clubs would somehow spice up the open source life a bit, won't they? But
to keep personal confusion at acceptable levels I prefer struggling with
the nice, meant-to-be-read code of the official package first.

 

Best,

jan

 

________________________________

Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im
Auftrag von jan-mathijs schoffelen
Gesendet: Dienstag, 23. November 2010 10:41
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] poor guys called Jan

 

Dear Jan,

 

Oops. Yes, I sincerely apologize for this one. I thought I took it out
already a while ago. I'll do it as we speak. Or would you prefer to have
the statistics_wrapperJM? Then we can start our own little
fieldtrip-twig ;o).

 

Cheers,

 

Jan-M

 

 

On Nov 23, 2010, at 10:34 AM, Jan Hirschmann wrote:





Hi,

 

as I am on it, I might as well make another minor improvement
suggestion. Ft_freqstatistics asks the system whether the user is named
jan and if so, calls statistics_wrapperJM instead of statistics_wrapper.
For people named Jan this is inconvenient, as the JM function is
probably found nowhere but on Jan-Mathijs' computer, I guess. What about
all the other Jans? :-)

 

Best,

jan

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---

 

Dr. J.M. (Jan-Mathijs) Schoffelen 

Donders Institute for Brain, Cognition and Behaviour, 
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands

J.Schoffelen at donders.ru.nl

Telephone: 0031-24-3614793

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/5a2f79ca/attachment-0001.htm>

From jan.schoffelen at DONDERS.RU.NL  Tue Nov 23 11:21:28 2010
From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen)
Date: Tue, 23 Nov 2010 11:21:28 +0100
Subject: AW: [FIELDTRIP] paths to connectivity function
In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8B01DC8D1A@Mail2-UKD.VMED.UKD>
Message-ID: <TUE.23.NOV.2010.112128.0100.FIELDTRIP@NIC.SURFNET.NL>

It seems as if ft_hastoolbox fails there (and does so unnoticed due to  
the try and catch statements). Could you check what happens if you  
comment out the try and catch?

Thanks,

JM

PS: for me it still works


On Nov 23, 2010, at 10:45 AM, Jan Hirschmann wrote:

> Dear Jan-Mathijs,
>
> I think I am. According to Matlabs which function at least, and the  
> code you are relating to is at line 112 in my function, too.
>
> Best,
> jan
>
> Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im  
> Auftrag von jan-mathijs schoffelen
> Gesendet: Dienstag, 23. November 2010 10:30
> An: FIELDTRIP at NIC.SURFNET.NL
> Betreff: Re: [FIELDTRIP] paths to connectivity function
>
> Dear Jan,
>
> Thanks for letting us know. As far as I can see, the function  
> fieldtripdefs tries to add the connectivity folder to the path (line  
> 112 of version 2017). Are you sure you are using the most recent  
> fieldtripdefs function?
>
> Best,
>
> JM
>
> On Nov 23, 2010, at 10:20 AM, Jan Hirschmann wrote:
>
>
>
> Dear fieldtrip developers,
>
> I have just installed the newest version as outlined on your website  
> (addpath without genpath and calling fieldtripdefs, old paths  
> removed). I noticed that calling ft_connectivityanalysis with method  
> “coh” now results in the error
>
> ??? Undefined function or method 'univariate2bivariate' for input  
> arguments of type ‘struct'.
>
> It is overcome by manually adding the folder connectivity to the  
> search path. Maybe fieldtripdefs does not include the connectivity  
> functions correctly?
>
> Best,
> jan
>
> Jan Hirschmann
> MSc. Neuroscience
> Insititute of Clinical Neuroscience and Medical Psychology
> Heinrich Heine University Duesseldorf
> Universitaetsstr.  1
> 40225  Duesseldorf
> Tel: 0049 - (0)211 - 81 - 18076
>
> --------------------------------------------------------------------------- You 
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the  
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>
>
> Dr. J.M. (Jan-Mathijs) Schoffelen
> Donders Institute for Brain, Cognition and Behaviour,
> Centre for Cognitive Neuroimaging,
> Radboud University Nijmegen, The Netherlands
> J.Schoffelen at donders.ru.nl
> Telephone: 0031-24-3614793
>
> --------------------------------------------------------------------------- You 
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the  
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>
> --------------------------------------------------------------------------- You 
>  are receiving this message because you are subscribed to
> the FieldTrip list. The aim of this list is to facilitate the  
> discussion
> between users of the FieldTrip toolbox, to share experiences
> and to discuss new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

Dr. J.M. (Jan-Mathijs) Schoffelen
Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands
J.Schoffelen at donders.ru.nl
Telephone: 0031-24-3614793


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/18e7e257/attachment-0001.htm>

From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE  Tue Nov 23 13:44:07 2010
From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann)
Date: Tue, 23 Nov 2010 13:44:07 +0100
Subject: AW: [FIELDTRIP] AW: [FIELDTRIP] paths to connectivity function
In-Reply-To: A<8AB02C02-18BF-4E34-9BE9-00E20D18CF78@donders.ru.nl>
Message-ID: <TUE.23.NOV.2010.134407.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi,

 

the problem was that in my startup file I add spm8 to the search path
which has its own fieldtrip. I should have used rmpath(genpath(...)) to
remove this fieldtrip but I only used rmpath(...). So it was my mistake,
sorry. In this context I wonder about the function fieldtripdefs. For
example, when spm8 is not on the path, it checks for the package with
ft_hastoolbox(spm8). The function returns an error message telling the
user that spm8 is not installed. However, the error message is never
displayed because ft_hastoolbox comes after a try statement. 

 

Best,

jan

 

________________________________

Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im
Auftrag von jan-mathijs schoffelen
Gesendet: Dienstag, 23. November 2010 11:21
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] AW: [FIELDTRIP] paths to connectivity function

 

It seems as if ft_hastoolbox fails there (and does so unnoticed due to
the try and catch statements). Could you check what happens if you
comment out the try and catch?

 

Thanks,

 

JM

 

PS: for me it still works

 

 

On Nov 23, 2010, at 10:45 AM, Jan Hirschmann wrote:





Dear Jan-Mathijs,

 

I think I am. According to Matlabs which function at least, and the code
you are relating to is at line 112 in my function, too.

 

Best,

jan

 

________________________________

Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im
Auftrag von jan-mathijs schoffelen
Gesendet: Dienstag, 23. November 2010 10:30
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] paths to connectivity function

 

Dear Jan,

 

Thanks for letting us know. As far as I can see, the function
fieldtripdefs tries to add the connectivity folder to the path (line 112
of version 2017). Are you sure you are using the most recent
fieldtripdefs function?

 

Best,

 

JM

 

On Nov 23, 2010, at 10:20 AM, Jan Hirschmann wrote:

 






Dear fieldtrip developers,

 

I have just installed the newest version as outlined on your website
(addpath without genpath and calling fieldtripdefs, old paths removed).
I noticed that calling ft_connectivityanalysis with method "coh" now
results in the error

 

??? Undefined function or method 'univariate2bivariate' for input
arguments of type 'struct'.

 

It is overcome by manually adding the folder connectivity to the search
path. Maybe fieldtripdefs does not include the connectivity functions
correctly?

 

Best,

jan

 

Jan Hirschmann

MSc. Neuroscience

Insititute of Clinical Neuroscience and Medical Psychology

Heinrich Heine University Duesseldorf

Universitaetsstr.  1
40225  Duesseldorf

Tel: 0049 - (0)211 - 81 - 18076

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---

 

Dr. J.M. (Jan-Mathijs) Schoffelen 

Donders Institute for Brain, Cognition and Behaviour, 
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands

J.Schoffelen at donders.ru.nl

Telephone: 0031-24-3614793

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---

 

Dr. J.M. (Jan-Mathijs) Schoffelen 

Donders Institute for Brain, Cognition and Behaviour, 
Centre for Cognitive Neuroimaging,
Radboud University Nijmegen, The Netherlands

J.Schoffelen at donders.ru.nl

Telephone: 0031-24-3614793

 

------------------------------------------------------------------------
--- You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion

between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
------------------------------------------------------------------------
---


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/d616f37e/attachment-0001.htm>

From tolgacan1 at YAHOO.COM  Tue Nov 23 15:58:10 2010
From: tolgacan1 at YAHOO.COM (=?iso-8859-1?Q?Tolga_=D6zkurt?=)
Date: Tue, 23 Nov 2010 06:58:10 -0800
Subject: Combining different MEG sensortypes
In-Reply-To: <893393094.122969.1290452084874.JavaMail.fmail@mwmweb053>
Message-ID: <TUE.23.NOV.2010.065810.0800.FIELDTRIP@NIC.SURFNET.NL>

This had also been a question in my mind for a while.
Hey Michael,


This had also been a question in my mind for a while.

As you say so, magnetometers and gradiometers have different noise levels and 
obviously different units; I believe the magnetoemeters are wegihted by some 
value like "100" in Maxwell Filtering (for SSS decomposition) to avoid the 
singularity in the gain matrix. However, when I tried the same weigthing for 
beamforming algorithm in the Fieldtrip toolbox for a real data experiment, I 
could not get a good performance when I compared the localization results to the 
results obtained with "only gradiometers" or "only magnetometers". That is, 
weighting 100 was not optimal; although the results was much better than the 
lozalization result "with no weighting" at all. This means some optimal 
weighting required.

I suppose it makes sense to use the fabric noise levels of the sensors while 
weighting them. There is also a way suggested by by Henson et. al. (2009) that 
uses a Bayesian scheme to obtain optimal noise estimates, although I did not 
attempt to work into that approach yet. 


By the way, could you tell me the date and title of the "the recent paper by 
Matthew Brookes" you mentioned? It sounds like an interesting one.

Regards,

Tolga  






----- Original Message ----
From: Michael Wibral <michael.wibral at WEB.DE>
To: FIELDTRIP at NIC.SURFNET.NL
Sent: Mon, November 22, 2010 7:54:44 PM
Subject: [FIELDTRIP] Combining different MEG sensortypes

Dear Fieldtrip users (with a Neuromag system),

I have a question on how to combine the Information from the planar gradiometers 
and the magnetometers of a 306 channel Neurmag system best for beamformer weight 
computation and source time course reconstruction. Do you compute a complete 
leadfield mixing both types of gradiometers (i.e. you do an unweighted 
analysis)? Do you somehow weight the sensors for their different noise levels? 
Do you compute two sets of timecourses (one from grads, one from megnetometers)?
A related question: Do you update the leadfileds for projections that 
MAxfiltering does (like it should be done when using ICA)?

I am asking because it has been shown that the more sensors are available the 
better the time course reconstruction (a recent paper by Matthew Brookes). Hence 
it would be a pity to have to throw some of the information away.

Michael

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------




---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From Nina.Kahlbrock at UNI-DUESSELDORF.DE  Tue Nov 23 15:58:34 2010
From: Nina.Kahlbrock at UNI-DUESSELDORF.DE (Nina Kahlbrock)
Date: Tue, 23 Nov 2010 15:58:34 +0100
Subject: statistics and NaNs in single channels
Message-ID: <TUE.23.NOV.2010.155834.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi all, 

I have a question concerning statistics and missing values.

I have data of 32 subjects (divided into four groups). Between these
subjects different channels were rejected due to artifacts. I would like to
avoid interpolating those channels but continue with filling up bad channels
with NaNs (i.e. subject one has channels 1, 3, and 17 filled up with NaNs,
subject two has channels 1, 7, 19, and 33 filled up with NaNs etc.).

What I would like to look at is if there are differences between groups in
certain cortical areas (I would calculate tfrs, average over certain
channels and then run a group analysis).

Does this pose a statistical problem, as there are differing numbers of
channels contributing to the average between groups? If I do not average
over channels, would it be allowed to identify significantly different
cortical areas between groups on sensor level?

Thank you in advance for any help!

Nina

 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - -

 

Nina Kahlbrock

Institute of Clinical Neuroscience and Medical Psychology 

Heinrich Heine University Duesseldorf

Universitaetsstr.  1

40225  Düsseldorf

 

Tel.:      +49 211 81 18075

Fax. .:   +49 211 81 19916

 

Mail:      <mailto:Nina.Kahlbrock at med.uni-duesseldorf.de>
Nina.Kahlbrock at med.uni-duesseldorf.de

 <http://www.uniklinik-duesseldorf.de/medpsychologie>
http://www.uniklinik-duesseldorf.de/medpsychologie

 


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/e8a30ea1/attachment-0001.htm>

From e.maris at DONDERS.RU.NL  Tue Nov 23 16:20:52 2010
From: e.maris at DONDERS.RU.NL (Eric Maris)
Date: Tue, 23 Nov 2010 16:20:52 +0100
Subject: statistics and NaNs in single channels
In-Reply-To: <004a01cb8b1e$e6f97920$cd136386@VMED.UKD>
Message-ID: <TUE.23.NOV.2010.162052.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Nina,

 

 

I would say, give it a try. When I programmed it (together with Robert
Oostenveld), the objective was to make all functions NaN-aware. I also
remember some successful tests. However, as far as I know, not many people
rely on the NaN-awareness of our code. So, Im curious what will happen.

 

Best,

 

 

dr. Eric Maris
Donders Institute for Brain, Cognition and Behavior

Radboud University
P.O. Box 9104
6500 HE Nijmegen
The Netherlands
T:+31 24 3612651
Mobile: 06 39584581

F:+31 24 3616066
mailto:e.maris at donders.ru.nl

http://www.nphyscog.com/

 

 

 

 

 

 

From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf
Of Nina Kahlbrock
Sent: dinsdag 23 november 2010 15:59
To: FIELDTRIP at NIC.SURFNET.NL
Subject: [FIELDTRIP] statistics and NaNs in single channels

 

Hi all, 

I have a question concerning statistics and missing values.

I have data of 32 subjects (divided into four groups). Between these
subjects different channels were rejected due to artifacts. I would like to
avoid interpolating those channels but continue with filling up bad channels
with NaNs (i.e. subject one has channels 1, 3, and 17 filled up with NaNs,
subject two has channels 1, 7, 19, and 33 filled up with NaNs etc.).

What I would like to look at is if there are differences between groups in
certain cortical areas (I would calculate tfrs, average over certain
channels and then run a group analysis).

Does this pose a statistical problem, as there are differing numbers of
channels contributing to the average between groups? If I do not average
over channels, would it be allowed to identify significantly different
cortical areas between groups on sensor level?

Thank you in advance for any help!

Nina

 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - -

 

Nina Kahlbrock

Institute of Clinical Neuroscience and Medical Psychology 

Heinrich Heine University Duesseldorf

Universitaetsstr.  1

40225  Düsseldorf

 

Tel.:      +49 211 81 18075

Fax. .:   +49 211 81 19916

 

Mail:      <mailto:Nina.Kahlbrock at med.uni-duesseldorf.de>
Nina.Kahlbrock at med.uni-duesseldorf.de

 <http://www.uniklinik-duesseldorf.de/medpsychologie>
http://www.uniklinik-duesseldorf.de/medpsychologie

 

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion 
between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/8f6e4875/attachment.htm>

From e.maris at DONDERS.RU.NL  Tue Nov 23 16:23:55 2010
From: e.maris at DONDERS.RU.NL (Eric Maris)
Date: Tue, 23 Nov 2010 16:23:55 +0100
Subject: statistics and NaNs in single channels
In-Reply-To: <004a01cb8b1e$e6f97920$cd136386@VMED.UKD>
Message-ID: <TUE.23.NOV.2010.162355.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Nina,

 

 

I forgot to answer part of your question. 

 

The presence of NaNs in your data does not pose any statistical problem. The
only relevant issue is whether our code can deal with the NaN-structure in
your data.

 

Best,

 

Eric

 

 

From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf
Of Nina Kahlbrock
Sent: dinsdag 23 november 2010 15:59
To: FIELDTRIP at NIC.SURFNET.NL
Subject: [FIELDTRIP] statistics and NaNs in single channels

 

Hi all, 

I have a question concerning statistics and missing values.

I have data of 32 subjects (divided into four groups). Between these
subjects different channels were rejected due to artifacts. I would like to
avoid interpolating those channels but continue with filling up bad channels
with NaNs (i.e. subject one has channels 1, 3, and 17 filled up with NaNs,
subject two has channels 1, 7, 19, and 33 filled up with NaNs etc.).

What I would like to look at is if there are differences between groups in
certain cortical areas (I would calculate tfrs, average over certain
channels and then run a group analysis).

Does this pose a statistical problem, as there are differing numbers of
channels contributing to the average between groups? If I do not average
over channels, would it be allowed to identify significantly different
cortical areas between groups on sensor level?

Thank you in advance for any help!

Nina

 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - -

 

Nina Kahlbrock

Institute of Clinical Neuroscience and Medical Psychology 

Heinrich Heine University Duesseldorf

Universitaetsstr.  1

40225  Düsseldorf

 

Tel.:      +49 211 81 18075

Fax. .:   +49 211 81 19916

 

Mail:      <mailto:Nina.Kahlbrock at med.uni-duesseldorf.de>
Nina.Kahlbrock at med.uni-duesseldorf.de

 <http://www.uniklinik-duesseldorf.de/medpsychologie>
http://www.uniklinik-duesseldorf.de/medpsychologie

 

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion 
between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/3c0b8a9e/attachment.htm>

From Nina.Kahlbrock at UNI-DUESSELDORF.DE  Tue Nov 23 17:02:14 2010
From: Nina.Kahlbrock at UNI-DUESSELDORF.DE (Nina Kahlbrock)
Date: Tue, 23 Nov 2010 17:02:14 +0100
Subject: AW: [FIELDTRIP] statistics and NaNs in single channels
In-Reply-To: <02bb01cb8b22$713b9430$53b2bc90$%maris@donders.ru.nl>
Message-ID: <TUE.23.NOV.2010.170214.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Eric, 

thank you very much for the quick answer!

I will try it and let you know if it worked.

Best, 

Nina

 

  _____  

Von: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] Im Auftrag
von Eric Maris
Gesendet: Dienstag, 23. November 2010 16:24
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] statistics and NaNs in single channels

 

Dear Nina,

 

 

I forgot to answer part of your question. 

 

The presence of NaNs in your data does not pose any statistical problem. The
only relevant issue is whether our code can deal with the NaN-structure in
your data.

 

Best,

 

Eric

 

 

From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf
Of Nina Kahlbrock
Sent: dinsdag 23 november 2010 15:59
To: FIELDTRIP at NIC.SURFNET.NL
Subject: [FIELDTRIP] statistics and NaNs in single channels

 

Hi all, 

I have a question concerning statistics and missing values.

I have data of 32 subjects (divided into four groups). Between these
subjects different channels were rejected due to artifacts. I would like to
avoid interpolating those channels but continue with filling up bad channels
with NaNs (i.e. subject one has channels 1, 3, and 17 filled up with NaNs,
subject two has channels 1, 7, 19, and 33 filled up with NaNs etc.).

What I would like to look at is if there are differences between groups in
certain cortical areas (I would calculate tfrs, average over certain
channels and then run a group analysis).

Does this pose a statistical problem, as there are differing numbers of
channels contributing to the average between groups? If I do not average
over channels, would it be allowed to identify significantly different
cortical areas between groups on sensor level?

Thank you in advance for any help!

Nina

 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - -

 

Nina Kahlbrock

Institute of Clinical Neuroscience and Medical Psychology 

Heinrich Heine University Duesseldorf

Universitaetsstr.  1

40225  Düsseldorf

 

Tel.:      +49 211 81 18075

Fax. .:   +49 211 81 19916

 

Mail:      <mailto:Nina.Kahlbrock at med.uni-duesseldorf.de>
Nina.Kahlbrock at med.uni-duesseldorf.de

 <http://www.uniklinik-duesseldorf.de/medpsychologie>
http://www.uniklinik-duesseldorf.de/medpsychologie

 

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion 
between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to 
the FieldTrip list. The aim of this list is to facilitate the discussion 
between users of the FieldTrip toolbox, to share experiences 
and to discuss new ideas for MEG and EEG analysis. 
See also http://listserv.surfnet.nl/archives/fieldtrip.html 
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101123/a62711f0/attachment.htm>

From michael.wibral at WEB.DE  Wed Nov 24 12:07:51 2010
From: michael.wibral at WEB.DE (Michael Wibral)
Date: Wed, 24 Nov 2010 12:07:51 +0100
Subject: Combining different MEG sensortypes
In-Reply-To: <353116.58039.qm@web111501.mail.gq1.yahoo.com>
Message-ID: <WED.24.NOV.2010.120751.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi Tolga,

very interesting to hear of your results and a bit disspointing to hear that "grad only" or "mag only" performed better for your case than the combination. Let me know if you make any progress on this.
The Brookes paper I was referring to is on noise reduction in recostructed source timecourse from EEG acquired with concurrent fMRI (Fig. 4 is what I was referring to):

Source localisation in concurrent EEG/fMRI: Applications at 7T
Matthew J. Brookes, Jiri Vrba b Karen J. Mullinger , Gerða Björk Geirsdóttir , Winston X. Yan ,
Claire M. Stevenson , Richard Bowtell , Peter G. Morris 

Michael

-----Ursprüngliche Nachricht-----
Von: "Tolga Özkurt" <tolgacan1 at YAHOO.COM>
Gesendet: Nov 23, 2010 3:58:10 PM
An: FIELDTRIP at NIC.SURFNET.NL
Betreff: Re: [FIELDTRIP] Combining different MEG sensortypes

>This had also been a question in my mind for a while.
>Hey Michael,
>
>
>This had also been a question in my mind for a while.
>
>As you say so, magnetometers and gradiometers have different noise levels and 
>obviously different units; I believe the magnetoemeters are wegihted by some 
>value like "100" in Maxwell Filtering (for SSS decomposition) to avoid the 
>singularity in the gain matrix. However, when I tried the same weigthing for 
>beamforming algorithm in the Fieldtrip toolbox for a real data experiment, I 
>could not get a good performance when I compared the localization results to the 
>results obtained with "only gradiometers" or "only magnetometers". That is, 
>weighting 100 was not optimal; although the results was much better than the 
>lozalization result "with no weighting" at all. This means some optimal 
>weighting required.
>
>I suppose it makes sense to use the fabric noise levels of the sensors while 
>weighting them. There is also a way suggested by by Henson et. al. (2009) that 
>uses a Bayesian scheme to obtain optimal noise estimates, although I did not 
>attempt to work into that approach yet. 
>
>
>By the way, could you tell me the date and title of the "the recent paper by 
>Matthew Brookes" you mentioned? It sounds like an interesting one.
>
>Regards,
>
>Tolga  
>
>
>
>
>
>
>----- Original Message ----
>From: Michael Wibral <michael.wibral at WEB.DE>
>To: FIELDTRIP at NIC.SURFNET.NL
>Sent: Mon, November 22, 2010 7:54:44 PM
>Subject: [FIELDTRIP] Combining different MEG sensortypes
>
>Dear Fieldtrip users (with a Neuromag system),
>
>I have a question on how to combine the Information from the planar gradiometers 
>and the magnetometers of a 306 channel Neurmag system best for beamformer weight 
>computation and source time course reconstruction. Do you compute a complete 
>leadfield mixing both types of gradiometers (i.e. you do an unweighted 
>analysis)? Do you somehow weight the sensors for their different noise levels? 
>Do you compute two sets of timecourses (one from grads, one from megnetometers)?
>A related question: Do you update the leadfileds for projections that 
>MAxfiltering does (like it should be done when using ICA)?
>
>I am asking because it has been shown that the more sensors are available the 
>better the time course reconstruction (a recent paper by Matthew Brookes). Hence 
>it would be a pity to have to throw some of the information away.
>
>Michael
>
>---------------------------------------------------------------------------
>You are receiving this message because you are subscribed to
>the  FieldTrip list. The aim of this list is to facilitate the discussion
>between  users of the FieldTrip  toolbox, to share experiences
>and to discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>---------------------------------------------------------------------------
>
>
>
>
>---------------------------------------------------------------------------
>You are receiving this message because you are subscribed to
>the  FieldTrip list. The aim of this list is to facilitate the discussion
>between  users of the FieldTrip  toolbox, to share experiences
>and to discuss  new ideas for MEG and EEG analysis.
>See also http://listserv.surfnet.nl/archives/fieldtrip.html
>and http://www.ru.nl/neuroimaging/fieldtrip.
>---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Michael Wibral.vcf
Type: text/x-vcard
Size: 628 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101124/78b5de37/attachment.vcf>

From r.vandermeij at DONDERS.RU.NL  Wed Nov 24 16:20:30 2010
From: r.vandermeij at DONDERS.RU.NL (Roemer van der Meij)
Date: Wed, 24 Nov 2010 16:20:30 +0100
Subject: new implementation of mtmconvol and mtmfft: specest
Message-ID: <WED.24.NOV.2010.162030.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear subscribers,

As of today, we have switched to a new implementation for the
'mtmconvol' and 'mtmfft' methods for frequency analysis. For a while now
we have been rewriting the low-level code in a different format, one
that is more flexible to adapt in the future and that allows for the
low-level algorithms to be downloaded in a separate module: /specest/.
The changes will be on our ftp-server by tonight.

The switch to the new implementation brings about several changes. With
respect to the changes are observable to the end-user, there are several
FAQs created at our wiki.

For the end-user observable changes for 'mtmconvol', please have a look
/here/
<http://fieldtrip.fcdonders.nl/faq/what_are_the_differences_between_the_old_and_the_new_implementation_of_mtmconvol_in_ft_freqanalyis>,
and for a bigger description with respect to your output.freq please go
/here/
<http://fieldtrip.fcdonders.nl/faq/why_does_my_output.freq_not_match_my_cfg.foi_when_using_mtmconvol_in_ft_freqanalyis>.

For the end-user observable changes for 'mtmfft', please have a look
/here/
<http://fieldtrip.fcdonders.nl/faq/what_are_the_differences_between_the_old_and_the_new_implementation_of_mtmfft_in_ft_freqanalyis>.

Because of these changes, it is advisable to either use the new or the
old implementation for your entire analysis project. We strongly advise
against combining or comparing data that have in part been produced by
the new implementation and in part by the old implementation, especially
when using phase information. The old implementation is still available
by using 'mtmconvol_old' or 'mtmfft_old' as cfg.method. However, this
code is deprecated and is no longer being updated. One can call also
call the function: ft_freqanalysis_old, which is the old interface-function.

If you are interested, you can track the progress of the /specest
/module by going /here/
<http://fieldtrip.fcdonders.nl/development/specest>. As soon as the
other low-level functions are ready and implemented, another e-mail will
be sent to the mailing-list.

If anything is unclear, or if there are any bugs that have slipped
through our fingers, please send an e-mail to the mailing-list and/or
report a bug in our /Bugzilla bug tracking system
<http://fieldtrip.fcdonders.nl/bugzilla>/.

Kind regards,

Roemer van der Meij


--
Roemer van der Meij MSc
PhD student
Donders Institute for Brain, Cognition and Behaviour
Centre for Cognition
P.O. Box 9104
6500 HE Nijmegen
The Netherlands
Tel: +31(0)24 3655932
E-mail: r.vandermeij at donders.ru.nl

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101124/db4f6560/attachment.htm>

From paul_c at GMX.DE  Thu Nov 25 10:10:32 2010
From: paul_c at GMX.DE (Paul Czienskowski)
Date: Thu, 25 Nov 2010 10:10:32 +0100
Subject: Electrode-Align
Message-ID: <THU.25.NOV.2010.101032.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear all,

I would like to know which you consider to be the best method to align a
set of electrodes to a BEM-Mesh. Starting with a real MRI I want to
align the 10-5-electrodes R. Oostenveld created and published at
http://robertoostenveld.ruhosting.nl/index.php/electrode/ to this. I
already tried ft_electroderealing to perform this task, but the
electrodes are still quite afar to the fiducials I used to align the
electrodes and even more to my headmodel. The model is a ~1000 Vertex
mesh created with the ft_prepare_mesh function.

Thanks in advance,
PC

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From paul_c at GMX.DE  Thu Nov 25 15:56:53 2010
From: paul_c at GMX.DE (Paul Czienskowski)
Date: Thu, 25 Nov 2010 15:56:53 +0100
Subject: Electrode-Align
In-Reply-To: <1290676232.5212.20.camel@mwb-desktop>
Message-ID: <THU.25.NOV.2010.155653.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Fieldtrippers,

by now I tried to use the 'interactive' mode of ft_electroderealign, but
for some reason the outcome is quite strange. In the
electrodes_interactive picture you see the electrodes aligned quite
well, at this point I close the figure to use those positions, but when
I plot the electrodes it looks like picture electrodes result.  I Tried
klicking apply in the 'interactive' mode too, but it changes nothing. Is
this a bug or am I doing sth. wrong?

Best,
Paul

Am Donnerstag, den 25.11.2010, 10:10 +0100 schrieb Paul Czienskowski:
> Dear all,
>
> I would like to know which you consider to be the best method to align a
> set of electrodes to a BEM-Mesh. Starting with a real MRI I want to
> align the 10-5-electrodes R. Oostenveld created and published at
> http://robertoostenveld.ruhosting.nl/index.php/electrode/ to this. I
> already tried ft_electroderealing to perform this task, but the
> electrodes are still quite afar to the fiducials I used to align the
> electrodes and even more to my headmodel. The model is a ~1000 Vertex
> mesh created with the ft_prepare_mesh function.
>
> Thanks in advance,
> PC
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------


---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: electrodes_interactive.jpg
Type: image/jpeg
Size: 31312 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101125/4f0203a1/attachment.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: electrodes_result.jpg
Type: image/jpeg
Size: 15821 bytes
Desc: not available
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20101125/4f0203a1/attachment-0001.jpg>

From mamashli at CBS.MPG.DE  Sat Nov 27 20:30:53 2010
From: mamashli at CBS.MPG.DE (Fahimeh Mamashli)
Date: Sat, 27 Nov 2010 20:30:53 +0100
Subject: ft_definetrail
Message-ID: <SAT.27.NOV.2010.203053.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi,
I have two subject data. they are almost the same. the first subject has sampling rate of 1000 and second subj 500 Hz.
I did definetrial for subject one, and fieldtrip did very well(created 37 trials) but when I run the same program for subject 2, it can just create one trail!! I can't understand it :(.
is anybody knows what is the reason? in which case ft_definetrial can just create one trail?! 

Thanks a lot,
Fahimeh
------------------------
PhD student
Max Planck Institute for Human Cognitive and Brain Sciences
Stephanstraße 1A 
04103 Leipzig
Germany

Tel: +49 341 9940 - 2570

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From mamashli at CBS.MPG.DE  Sat Nov 27 21:28:08 2010
From: mamashli at CBS.MPG.DE (Fahimeh Mamashli)
Date: Sat, 27 Nov 2010 21:28:08 +0100
Subject: ft_definetrial
In-Reply-To: <1939783.520.1290888797032.JavaMail.root@zimbra>
Message-ID: <SAT.27.NOV.2010.212808.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi again,
sorry I found out myself!
I discovered the problem. maybe it is interesting for others:
sometimes it seems routine ft_definetrial can not find all the events based on its default definition.
this is the routine way in ft_definetrail:

cfg34                         = [];
cfg34.dataset                 = '../rawdir/cp02a/cp02a4.fif';
cfg34.trialdef.eventtype      = 'STI101';
cfg34.trialdef.eventvalue     = 34; 
cfg34.trialdef.prestim        = 0.1;
cfg34.trialdef.poststim       = 0.6;

cfg34 = ft_definetrial(cfg34);

but I the problem is that, It could not detect all the events. so I did as follows to find all the event values:

hdr = ft_read_header('../rawdir/cp02a/cp02a1.fif');
[event] = ft_read_event('../rawdir/cp02a/cp02a1.fif','header',hdr,'detectflank','down');

cfg34                         = [];
cfg34.dataset                 = '../rawdir/cp02a/cp02a4.fif';

cfg34.event=event;

cfg34.trialdef.eventtype      = 'STI101';
cfg34.trialdef.eventvalue     = 34; 
cfg34.trialdef.prestim        = 0.1;
cfg34.trialdef.poststim       = 0.6;

cfg34 = ft_definetrial(cfg34);

the point is to change 'detectflank','down'! the default is 'up' and in my data it could not detect events.

because in default events I just had one event value '34'!! but after changing detectflank, it found 35!!

Best wishes,
Fahimeh 

------------------------
PhD student
Max Planck Institute for Human Cognitive and Brain Sciences
Stephanstraße 1A 
04103 Leipzig
Germany

Tel: +49 341 9940 - 2570

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From manish.saggar at GMAIL.COM  Mon Nov 29 06:46:51 2010
From: manish.saggar at GMAIL.COM (Manish Saggar)
Date: Sun, 28 Nov 2010 23:46:51 -0600
Subject: avgoverfreq is good or bad?
In-Reply-To: <5353627433516540283@unknownmsgid>
Message-ID: <SUN.28.NOV.2010.234651.0600.FIELDTRIP@NIC.SURFNET.NL>

Dear Eric,

Thanks for explaining in detail and apologies for late reply, I was on vacation.

Regards,
m-


On Sat, Nov 20, 2010 at 6:41 AM, Eric Maris <e.maris at donders.ru.nl> wrote:
> Dear Manish,
>
>
> As a rule, whenever you incorporate valid prior information in your
> statistical analysis, you will increase sensitivity. For instance, assume
> that there physiological reasons why effects should always occur in a number
> of discrete frequency bands; [0.5,1.5] (delta), [4,6] (theta), [8,12]
> (alpha), [13,30] (beta), and [31,80] (gamma). Then, you will increase power
> by (1) estimating the average power in these frequency bands (using
> multitaper estimation with the appropriate spectral smoothing), and (2)
> performing a cluster-based permutation test on the resulting
> (channel,frequency bin)-data. Without frequency smoothing in the a priori
> defined frequency intervals sensitivity will be lower, assumed the intervals
> are valid of course. You can further increase sensitivity if you know a
> priori that effects will only occur in one of the frequency bands, but that
> does not seem to be the case for you.
>
> Good luck,
>
> Eric Maris
>
>
> dr. Eric Maris
> Donders Institute for Brain, Cognition and Behavior
> Center for Cognition and F.C. Donders Center for Cognitive Neuroimaging
> Radboud University
> P.O. Box 9104
> 6500 HE Nijmegen
> The Netherlands
> T:+31 24 3612651
> Mobile: 06 39584581
> F:+31 24 3616066
> E: e.maris at donders.ru.nl
>
>
>
>
>
>
>
>> -----Original Message-----
>> From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On
>> Behalf Of Manish Saggar
>> Sent: zaterdag 20 november 2010 8:21
>> To: FIELDTRIP at NIC.SURFNET.NL
>> Subject: [FIELDTRIP] avgoverfreq is good or bad?
>>
>> Dear all,
>>
>> I have spatio-spectral EEG data (no temporal information) from two
>> groups. Group A was tested three times (t1,t2,t3) during a treatment
>> and group B (control group) was also tested at the same three time
>> points. Now I simply want to know which <channel, frequency> pairs
>> differ for each group separately. Thus, I ran depsamplesF test
>> (cluster with montecarlo) for each group for a large frequency range,
>> say 0.5 - 100Hz, cfg.avgoverfreq = 'no'.  I then used Bonferroni
>> correction (for two tests) and plotted the clusters using multiplotTFR
>> with 'mask' as zstat parameter. The clusters of <ch, freq> I get are
>> mostly in 15-40Hz range and usually there is only one big cluster.
>>
>> Now my question is - by running over a huge range of frequency (using
>> no averaging over freq), did I lower the power for low freq bands
>> (like delta, theta, and alpha)? Should I rather run these tests
>> separately for low freq bands (like delta, theta, and alpha) with
>> avgoverfreq='yes'. And may be another test for high frequencies like
>> 14-100 Hz with no averaging over frequencies.
>>
>> The reason I was running one test for all frequencies was to avoid
>> multiple tests and hence avoiding more stringent Bonferroni
>> correction.
>>
>> Thanks,
>> m-
>>
>>
>>
>> Manish Saggar,
>> Doctoral Candidate,
>> Department of Computer Science,
>> The University of Texas at Austin,
>> Web: http://www.cs.utexas.edu/~mishu/
>> Email: mishu at cs.utexas.edu
>>
>> -----------------------------------------------------------------------
>> ----
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the
>> discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> -----------------------------------------------------------------------
>> ----
>
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------
>

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From seapsy at GMAIL.COM  Tue Nov 30 14:47:22 2010
From: seapsy at GMAIL.COM (Seapsy Seapsy)
Date: Tue, 30 Nov 2010 14:47:22 +0100
Subject: read NeuroScan avg file
Message-ID: <TUE.30.NOV.2010.144722.0100.FIELDTRIP@NIC.SURFNET.NL>

dear all:
i am the new fieldtripers.
I got some  averaged *.avg files from neuroscan 4.3 Now i want to plot 
topographic distributed with fieldtrip. But  i don't know how to convert the AVG 
file to fieldtrip structure.
Could anybody help me with this? 


Thanks a lot


              seapsy

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From r.oostenveld at DONDERS.RU.NL  Tue Nov 30 21:07:42 2010
From: r.oostenveld at DONDERS.RU.NL (Robert Oostenveld)
Date: Tue, 30 Nov 2010 21:07:42 +0100
Subject: read NeuroScan avg file
In-Reply-To: <LISTSERV%201011301447223900.F043@NIC.SURFNET.NL>
Message-ID: <TUE.30.NOV.2010.210742.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Seapsy

A file with an averaged ERP in it is treated just as any other file. The code below specifies that a single "trial/segment" should be constructed corresponding with the "average" event

cfg = []
cfg.trialdef.eventtype = 'average' % this is the important line
cfg.dataset = '0500e.avg' % this is a testfile I have
cfg = ft_definetrial(cfg);

% the following reads the data as a single trial
% this is also where you would do filters and baseline correction
raw = ft_preprocessing(cfg);

% the following "averages" the single trial, the consequence is just that the raw single-trial data representation is converted to a ERP data structure
avg = ft_timelockanalysis([], raw)

% please compare the raw and the avg data structure, the numbers representing the data are the same, only the structure is different

% the following plots the ERP
% my example file has channel names that correspond to the EEG-1020 layout, which is located in fieldtrip/template/EEG1020.lay
cfg = []
cfg.layout = 'EEG1010.lay'
cfg.interactive = 'yes'
ft_multiplotER(cfg, avg)

The cfg.interactive=yes option allows you to click in the figure select a subset of channels, over which you get the averaged ERP. In the following figure you can subsequently select the time window, resulting in the 3rd figure with the topography. See http://fieldtrip.fcdonders.nl/tutorial/plotting for more details on plotting and http://fieldtrip.fcdonders.nl/tutorial/layout for details on how to create a layout (which is a requirement for the plotting of the data on the correct 2D channel locations).

good luck
Robert



On 30 Nov 2010, at 14:47, Seapsy Seapsy wrote:

> dear all:
> i am the new fieldtripers.
> I got some  averaged *.avg files from neuroscan 4.3 Now i want to plot 
> topographic distributed with fieldtrip. But  i don't know how to convert the AVG 
> file to fieldtrip structure.
> Could anybody help me with this? 
> 
> 
> Thanks a lot
> 
> 
>              seapsy
> 
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From r.oostenveld at DONDERS.RU.NL  Tue Nov 30 21:12:09 2010
From: r.oostenveld at DONDERS.RU.NL (Robert Oostenveld)
Date: Tue, 30 Nov 2010 21:12:09 +0100
Subject: Electrode-Align
In-Reply-To: <1290697013.2637.21.camel@paul-desktop>
Message-ID: <TUE.30.NOV.2010.211209.0100.FIELDTRIP@NIC.SURFNET.NL>

Dear Paul,

the first figure indeed looks quite ok. The remaining distance from the electrodes to the scalp will be removed in the BEM model setup in which the electrodes are projected on to the skin.

However, I dont understand the subsequent problem. Please file a bug at bugzilla.fcdonders.nl and attach a small *.mat file with the cfg that you give as input, i.e. such that the problem can be reproduced with 

load file.mat
elec = ft_electroderealign(cfg)
 
best,
Robert



On 25 Nov 2010, at 15:56, Paul Czienskowski wrote:

> Dear Fieldtrippers,
> 
> by now I tried to use the 'interactive' mode of ft_electroderealign, but
> for some reason the outcome is quite strange. In the
> electrodes_interactive picture you see the electrodes aligned quite
> well, at this point I close the figure to use those positions, but when
> I plot the electrodes it looks like picture electrodes result.  I Tried
> klicking apply in the 'interactive' mode too, but it changes nothing. Is
> this a bug or am I doing sth. wrong?
> 
> Best,
> Paul
> 
> Am Donnerstag, den 25.11.2010, 10:10 +0100 schrieb Paul Czienskowski:
>> Dear all,
>> 
>> I would like to know which you consider to be the best method to align a
>> set of electrodes to a BEM-Mesh. Starting with a real MRI I want to
>> align the 10-5-electrodes R. Oostenveld created and published at
>> http://robertoostenveld.ruhosting.nl/index.php/electrode/ to this. I
>> already tried ft_electroderealing to perform this task, but the
>> electrodes are still quite afar to the fiducials I used to align the
>> electrodes and even more to my headmodel. The model is a ~1000 Vertex
>> mesh created with the ft_prepare_mesh function.
>> 
>> Thanks in advance,
>> PC

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From r.oostenveld at DONDERS.RU.NL  Tue Nov 30 21:18:49 2010
From: r.oostenveld at DONDERS.RU.NL (Robert Oostenveld)
Date: Tue, 30 Nov 2010 21:18:49 +0100
Subject: Combining different MEG sensortypes
In-Reply-To: <1780892590.1052312.1290596871092.JavaMail.fmail@mwmweb054>
Message-ID: <TUE.30.NOV.2010.211849.0100.FIELDTRIP@NIC.SURFNET.NL>

Hi Tolga and Michael,

This reminds me of a bug that was in the code "once upon a time". That bug caused a sign difference on the gradiometer and magnetometers in the leadfield. Now hearing this problem, I am not 100% sure whether that bug has been resolved. 

If that bug still lingers in the code somehow, it might explain the results of each seperate being better than the combined reconstruction (because the combined channels would result in inconsistent/flipped source orientations). Do you perhaps have a neuromag phantom dataset, i.e. real data with the correct field distribution of a simple source? If so, then you can fit the source (using ft_dipolefitting) with "mag only" and with "grad only" and compare the dipole orientation. Or fit with mag only, compute the leadfield on mag and grad, and compare the computed leadfield with the true data.

best
Robert


On 24 Nov 2010, at 12:07, Michael Wibral wrote:

> Hi Tolga,
> 
> very interesting to hear of your results and a bit disspointing to hear that "grad only" or "mag only" performed better for your case than the combination. Let me know if you make any progress on this.
> The Brookes paper I was referring to is on noise reduction in recostructed source timecourse from EEG acquired with concurrent fMRI (Fig. 4 is what I was referring to):
> 
> Source localisation in concurrent EEG/fMRI: Applications at 7T
> Matthew J. Brookes, Jiri Vrba b Karen J. Mullinger , Gerða Björk Geirsdóttir , Winston X. Yan ,
> Claire M. Stevenson , Richard Bowtell , Peter G. Morris 
> 
> Michael
> 
> -----Ursprüngliche Nachricht-----
> Von: "Tolga Özkurt" <tolgacan1 at YAHOO.COM>
> Gesendet: Nov 23, 2010 3:58:10 PM
> An: FIELDTRIP at NIC.SURFNET.NL
> Betreff: Re: [FIELDTRIP] Combining different MEG sensortypes
> 
>> This had also been a question in my mind for a while.
>> Hey Michael,
>> 
>> 
>> This had also been a question in my mind for a while.
>> 
>> As you say so, magnetometers and gradiometers have different noise levels and 
>> obviously different units; I believe the magnetoemeters are wegihted by some 
>> value like "100" in Maxwell Filtering (for SSS decomposition) to avoid the 
>> singularity in the gain matrix. However, when I tried the same weigthing for 
>> beamforming algorithm in the Fieldtrip toolbox for a real data experiment, I 
>> could not get a good performance when I compared the localization results to the 
>> results obtained with "only gradiometers" or "only magnetometers". That is, 
>> weighting 100 was not optimal; although the results was much better than the 
>> lozalization result "with no weighting" at all. This means some optimal 
>> weighting required.
>> 
>> I suppose it makes sense to use the fabric noise levels of the sensors while 
>> weighting them. There is also a way suggested by by Henson et. al. (2009) that 
>> uses a Bayesian scheme to obtain optimal noise estimates, although I did not 
>> attempt to work into that approach yet. 
>> 
>> 
>> By the way, could you tell me the date and title of the "the recent paper by 
>> Matthew Brookes" you mentioned? It sounds like an interesting one.
>> 
>> Regards,
>> 
>> Tolga  
>> 
>> 
>> 
>> 
>> 
>> 
>> ----- Original Message ----
>> From: Michael Wibral <michael.wibral at WEB.DE>
>> To: FIELDTRIP at NIC.SURFNET.NL
>> Sent: Mon, November 22, 2010 7:54:44 PM
>> Subject: [FIELDTRIP] Combining different MEG sensortypes
>> 
>> Dear Fieldtrip users (with a Neuromag system),
>> 
>> I have a question on how to combine the Information from the planar gradiometers 
>> and the magnetometers of a 306 channel Neurmag system best for beamformer weight 
>> computation and source time course reconstruction. Do you compute a complete 
>> leadfield mixing both types of gradiometers (i.e. you do an unweighted 
>> analysis)? Do you somehow weight the sensors for their different noise levels? 
>> Do you compute two sets of timecourses (one from grads, one from megnetometers)?
>> A related question: Do you update the leadfileds for projections that 
>> MAxfiltering does (like it should be done when using ICA)?
>> 
>> I am asking because it has been shown that the more sensors are available the 
>> better the time course reconstruction (a recent paper by Matthew Brookes). Hence 
>> it would be a pity to have to throw some of the information away.
>> 
>> Michael
>> 
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
>> 
>> 
>> 
>> 
>> ---------------------------------------------------------------------------
>> You are receiving this message because you are subscribed to
>> the  FieldTrip list. The aim of this list is to facilitate the discussion
>> between  users of the FieldTrip  toolbox, to share experiences
>> and to discuss  new ideas for MEG and EEG analysis.
>> See also http://listserv.surfnet.nl/archives/fieldtrip.html
>> and http://www.ru.nl/neuroimaging/fieldtrip.
>> ---------------------------------------------------------------------------
> 
> ---------------------------------------------------------------------------
> You are receiving this message because you are subscribed to
> the  FieldTrip list. The aim of this list is to facilitate the discussion
> between  users of the FieldTrip  toolbox, to share experiences
> and to discuss  new ideas for MEG and EEG analysis.
> See also http://listserv.surfnet.nl/archives/fieldtrip.html
> and http://www.ru.nl/neuroimaging/fieldtrip.
> ---------------------------------------------------------------------------<Michael Wibral.vcf>

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From lhunt at FMRIB.OX.AC.UK  Tue Nov 30 21:48:46 2010
From: lhunt at FMRIB.OX.AC.UK (Laurence Hunt)
Date: Tue, 30 Nov 2010 20:48:46 +0000
Subject: Combining different MEG sensortypes
In-Reply-To: <F3CA5838-B845-4338-B5C3-961FA80345DA@donders.ru.nl>
Message-ID: <TUE.30.NOV.2010.204846.0000.FIELDTRIP@NIC.SURFNET.NL>

Hi guys - 

I believe this bug was fixed on 15th July this year, so any version of fieldtrip preceding this will still have a sign-difference issue between gradiometers and magnetometers. (This should not be an issue for an analysis using each modality separately (unless you are critically interested in dipole orientation), or analyses using SPM's source reconstruction routines (spm_eeg_invert_fuse estimates a scale factor for both magnetometers and gradiometers, and this factor can go negative as well as positive), but will be an issue for these beamformer source reconstructions). 

It would be great if someone was able to check this with a phantom - we are hoping to do something similar in Oxford soon.

Cheers,
Laurence

===========================================
Laurence Hunt, DPhil Student
 Centre for Functional MRI of the Brain (FMRIB), 
University of Oxford
lhunt at fmrib.ox.ac.uk
Phone: (+44)1865-(2)22738
===========================================

On 30 Nov 2010, at 20:18, Robert Oostenveld wrote:

> This reminds me of a bug that was in the code "once upon a time". That bug caused a sign difference on the gradiometer and magnetometers in the leadfield. Now hearing this problem, I am not 100% sure whether that bug has been resolved. 

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


From manish.saggar at GMAIL.COM  Tue Nov 30 23:25:52 2010
From: manish.saggar at GMAIL.COM (Manish Saggar)
Date: Tue, 30 Nov 2010 16:25:52 -0600
Subject: how to use depsamplesF as an omnibus anova?
Message-ID: <TUE.30.NOV.2010.162552.0600.FIELDTRIP@NIC.SURFNET.NL>

Dear all,

I have 81ch EEG data (no trials only continuous data) from two groups:
A and B. Each group was tested at three test points t1, t2,and t3. One
of the group received treatment and other one didn't (control).

Now in order to test the effects of treatment across time in each
group, we want to use nonparametric analysis. I am doing depsamplesF
test for three test-points in each group separately (followed by
Bonferroni Correction for doing 2 such tests) and if I find a positive
cluster in depsamplesF test then I will take that as a permission to
go in and test t1 vs. t2, t2 vs. t3, and t3 vs. t1 for that group.
Ideally I should not get any such cluster in control group. So my
first question is that does this approach sounds reasonable? For these
two depsamplesF test I am keeping the foi = [0.5 - 100], with
avgoverfreq='no'. Reason for this broad range frequency is that I am
keeping this level as more of an exploratory type analysis and want to
keep bonferroni corrections to minimum (not sure if I can assume
different freq bands as independent or dependent and thereby need
posthoc corrections or not?).

Now in addition to saying that three test-points differ (if positive
cluster), depsamplesF test also gives us <channel, freq>
pairs/clusters that differs in each group. In my case, it usually
gives only one such cluster and that usually covers 2/3 of the
channels and a freq range of 10-40Hz. Now since the sensitivity of
these depsamplesF might be low (due to huge foi range). Is it
reasonable to just take these depsamplesF as an indication that
something differs but ignore the cluster where things differ. Then do
t1 vs t2... and so on tests with defined low-freq bands (delta, theta,
alpha) and high-freq bands (beta and gamma) and using
avgoverfreq='yes' for those, so that the sensitivity can be increased.

Thus, using depsamplesF test as an omni bus anova and just find out if
something differs. If it does, then *not* take the cluster that
differs rather re do cluster analysis for three lower level tests (t1
vs t2... so on) with more sensitive freq bands and avgoverfreq='yes'
over all channels. Is it a reasonable approach?

I apologize in advance if something is not clear or if I am using
wrong terminology.

Thanks for all your great work and help.

Regards,
Manish

---------------------------------------------------------------------------
You are receiving this message because you are subscribed to
the  FieldTrip list. The aim of this list is to facilitate the discussion
between  users of the FieldTrip  toolbox, to share experiences
and to discuss  new ideas for MEG and EEG analysis.
See also http://listserv.surfnet.nl/archives/fieldtrip.html
and http://www.ru.nl/neuroimaging/fieldtrip.
---------------------------------------------------------------------------


