<div dir="ltr"><div class="gmail_default"><font face="times new roman, serif" size="4" color="#000000">Hello,<br></font></div><div class="gmail_default"><font color="#000000" face="times new roman, serif" size="4"><br></font></div><div class="gmail_default"><font face="times new roman, serif" size="4" color="#000000">I'm trying to conduct behavior-power correlations. This topic has been discussed a few times before (<a href="http://mailman.science.ru.nl/pipermail/fieldtrip/2015-February/008953.html">http://mailman.science.ru.nl/pipermail/fieldtrip/2015-February/008953.html</a> and <a href="http://mailman.science.ru.nl/pipermail/fieldtrip/2015-October/009720.html">http://mailman.science.ru.nl/pipermail/fieldtrip/2015-October/009720.html</a>), but I'm still having issues getting it to work. I'm working with a grand averaged structure of 25 individuals' frequency data, and trying to correlate it with a proficiency measurement (one value per person).</font></div><div class="gmail_default"><font face="times new roman, serif" size="4" color="#000000"><br></font></div><div class="gmail_default"><font face="times new roman, serif" size="4" color="#000000">If I follow the instructions on the tutorial (<a href="http://www.fieldtriptoolbox.org/faq/how_can_i_test_for_correlations_between_neuronal_data_and_quantitative_stimulus_and_behavioural_variables">http://www.fieldtriptoolbox.org/faq/how_can_i_test_for_correlations_between_neuronal_data_and_quantitative_stimulus_and_behavioural_variables</a>), I get an error that "uvar must be specified for
dependent samples statistics". I tried various permutations of the design including a uvar got the error "<span style="text-indent: -0.25in;">Invalid specification of the design array."</span></font><span style="color:rgb(0,0,0);font-family:'times new roman',serif;font-size:large">  When I tried a suggestion in the previous email threads to </span><span style="color:rgb(0,0,0);font-family:'times new roman',serif;font-size:large">​create a dummy variable that is a copy of my frequency data, and replace the power spectrum with the behavioral measure, and create a design with their code:</span></div><div class="gmail_default"><p style="margin:0px;line-height:normal"><font face="times new roman, serif" size="4" color="#000000">cfg.design = [];</font></p>
<p style="margin:0px;line-height:normal"><font face="times new roman, serif" size="4" color="#000000">cfg.design(1,:) = [ones(1,length(BehVar)) 2*ones(1,length(BehVar))];</font></p>
<p style="margin:0px;line-height:normal"><font face="times new roman, serif" size="4" color="#000000">cfg.design(2,:) = [1:length(BehVar) 1:length(BehVar)];</font></p>
<p style="margin:0px;line-height:normal;min-height:14px"><font face="times new roman, serif" size="4" color="#000000"><br></font></p><p style="margin:0px;line-height:normal;min-height:14px"><font face="times new roman, serif" size="4" color="#000000">I get the error "the length of the design matrix (2) does not match the number of observations in the data (25)".</font></p><p style="margin:0px;line-height:normal;min-height:14px"><font face="times new roman, serif" size="4" color="#000000"><br></font></p><p style="margin:0px;line-height:normal;min-height:14px"><font face="times new roman, serif" size="4" color="#000000">My question is this: what is the appropriate design array for computing a correlation with ft_statfun_correlationT? Is the behavioral variable supposed to be part of the design or must it be part of a dummy structure designed to be similar in size and structure to the frequency data?</font></p><p style="margin:0px;line-height:normal;min-height:14px"><font face="times new roman, serif" size="4" color="#000000"><br></font></p><p style="margin:0px;line-height:normal;min-height:14px"><font face="times new roman, serif" size="4" color="#000000">Alternatively, is there a way to get, for every individual in the grand average, one value representing the average power for, e.g., 300-600ms in the 4-7Hz range?</font></p><p style="margin:0px;line-height:normal;min-height:14px"><font face="times new roman, serif" size="4" color="#000000"><br></font></p><p style="margin:0px;line-height:normal;min-height:14px"><span style="color:rgb(0,0,0);font-family:'times new roman',serif;font-size:large">Thank you very much for your help,</span><br></p><p style="margin:0px;line-height:normal;min-height:14px"><font face="times new roman, serif" size="4" color="#000000">Kaitlyn Litcofsky</font></p><div><font face="times new roman, serif" size="4" color="#000000"><br></font></div></div><div><font face="times new roman, serif" size="4" color="#000000"><br></font></div><font face="times new roman, serif" size="4" color="#000000">-- <br></font><div class="gmail_signature"><div dir="ltr"><font face="times new roman, serif" size="4" color="#000000">Kaitlyn Litcofsky</font><div><font face="times new roman, serif" size="4" color="#000000">Graduate Student, Cognitive Psychology</font></div><div><font face="times new roman, serif" size="4" color="#000000">006 Moore Building</font></div><div><font face="times new roman, serif" size="4" color="#000000">Pennsylvania State University</font></div><div><font face="times new roman, serif" size="4" color="#000000">University Park, PA 16802</font></div><div><font face="times new roman, serif" size="4" color="#000000">Email: <a href="mailto:kal378@psu.edu" target="_blank">kal378@psu.edu</a></font></div></div></div>
</div>