Dear Eric,<div><br></div><div>I have tried the between-trials experiment too, but the two problems still remain (the statfun_indepsamplesZcoh looks for label field. Furtheremore if I add it the reshape function crashes). Any other suggestions?</div>
<div><br></div><div>I have also another question relative to your reply: the baseline and activation trials were already divided in the within-trials experiment, the only difference with the between-trials experiment are relative to the configuration parameters (i.e. in between-trials only cfg.ivar is set while in within-trials cfg.ivar and cfg.uvar are set) am I wrong?</div>
<div><br></div><div>Regarding the 'label field' problem, it seems a required field for the configuration struct because it is used in statfun_indepsamplesZcoh to calculate the channel combinations for the coherence. </div>
<div><br></div><div>Thanks a lot</div><div><br></div><div>Matteo</div><div><br></div><div><br><br><div class="gmail_quote">On Wed, Apr 28, 2010 at 9:17 AM, Eric Maris <span dir="ltr"><<a href="mailto:e.maris@donders.ru.nl">e.maris@donders.ru.nl</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div lang="NL" link="blue" vlink="purple">
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">Dear Matteo,</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;color:#1F497D">The statfun indepsamplesZcoh can only be used in a
between-trials experiment. You could cut out your baseline and activation
segments separately and then compare them in a non-paired fashion.</span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;color:#1F497D"> </span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;color:#1F497D"> </span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;color:#1F497D">Best,</span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;color:#1F497D"> </span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;color:#1F497D">Eric</span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;color:#1F497D"> </span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;color:#1F497D"> </span></p>
<div style="border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt">
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt">From:</span></b><span lang="EN-US" style="font-size:10.0pt"> FieldTrip discussion list
[mailto:<a href="mailto:FIELDTRIP@NIC.SURFNET.NL" target="_blank">FIELDTRIP@NIC.SURFNET.NL</a>] <b>On Behalf Of </b>Matteo Demuru<br>
<b>Sent:</b> dinsdag 27 april 2010 16:21<br>
<b>To:</b> <a href="mailto:FIELDTRIP@NIC.SURFNET.NL" target="_blank">FIELDTRIP@NIC.SURFNET.NL</a><br>
<b>Subject:</b> [FIELDTRIP] Non parametric test on coherence</span></p>
</div>
</div><div><div></div><div class="h5">
<p class="MsoNormal"> </p>
<p class="MsoNormal">Dear all,</p>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">I have a problem using freqstatistics to calculate
significance for coherence.</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">Specifically I have a subject and I am performing a
within-trials experiment using 'indepsamplesZcoh' as statistic.</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">I calculate the TFR of my data with the
cfg.output='powandcsd' and cfg.keeptrials='yes' parameters. Then I call
freqstatistics to compare my different experimental conditions (baseline vs
activation).</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">The function crashes with this output: </p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<div>
<p class="MsoNormal">??? Reference to non-existent field 'label'.</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">Error in ==> statfun_indepsamplesZcoh at 76</p>
</div>
<div>
<p class="MsoNormal"> nchan = length(cfg.label);</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">I have tried to add this field to the cfg struct assigning
the cell that contains the interested channels. However this time I have
another error:</p>
</div>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">??? Error using ==> reshape</p>
</div>
<div>
<p class="MsoNormal">To RESHAPE the number of elements must not change.</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">Error in ==> clusterstat at 178</p>
</div>
<div>
<p class="MsoNormal"> posclusobs =
findcluster(reshape(postailobs,
[cfg.dim,1]),channeighbstructmat,cfg.minnbchan);</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">Any suggestions?</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">Thanks in advance</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">Matteo Demuru</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
</div></div><p>----------------------------------</p>
<p>The aim of this list is to facilitate the discussion between users of the
FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and
EEG analysis.</p>
<p><a href="http://listserv.surfnet.nl/archives/fieldtrip.html" target="_blank">http://listserv.surfnet.nl/archives/fieldtrip.html</a></p>
<p><a href="http://www.ru.nl/fcdonders/fieldtrip/" target="_blank">http://www.ru.nl/fcdonders/fieldtrip/</a></p>
</div>
</div>
</div>
<p>----------------------------------</p>
<p>The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis.</p>
<p> <a href="http://listserv.surfnet.nl/archives/fieldtrip.html" target="_blank">http://listserv.surfnet.nl/archives/fieldtrip.html</a></p>
<p> <a href="http://www.ru.nl/fcdonders/fieldtrip/" target="_blank">http://www.ru.nl/fcdonders/fieldtrip/</a></p>
</blockquote></div><br></div>
<p>----------------------------------</p>
<p>The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis.</p>
<p> http://listserv.surfnet.nl/archives/fieldtrip.html</p>
<p> http://www.ru.nl/fcdonders/fieldtrip/</p>