<div dir="ltr"><div><div><div>Dear Caroline,<br><br></div>If your conditions are within-subject, then I think the best way to do this is to construct a dataset representing the conditionA - conditionB difference for each subject, and then using ft_statfun_indepsamplesregrT to regress the subject-wise difference on age. See e.g. <a href="https://mailman.science.ru.nl/pipermail/fieldtrip/2016-May/010528.html">https://mailman.science.ru.nl/pipermail/fieldtrip/2016-May/010528.html</a> for a thread discussing a similar approach.<br><br></div>Best,<br></div>Steve<br><div><div><div><div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><br></div><span><div>---<br></div>Stephen Politzer-Ahles<br>The Hong Kong Polytechnic University<br>Department of Chinese and Bilingual Studies<br><a href="http://www.mypolyuweb.hk/%7Esjpolit/" target="_blank">http://www.mypolyuweb.hk/~sjpolit/</a></span><a href="http://www.nyu.edu/projects/politzer-ahles/" target="_blank"></a></div></div></div></div></div></div></div></div></div>
<br><div class="gmail_quote"><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Message: 3<br>
Date: Mon, 10 Apr 2017 14:50:13 +0200 (CEST)<br>
From: Caroline Beese <<a href="mailto:beese@cbs.mpg.de">beese@cbs.mpg.de</a>><br>
To: <a href="mailto:fieldtrip@science.ru.nl">fieldtrip@science.ru.nl</a><br>
Subject: [FieldTrip] cluster-based statistics with one covariate<br>
Message-ID:<br>
        <<a href="mailto:1329277450.115066.1491828613491.JavaMail.zimbra@cbs.mpg.de">1329277450.115066.<wbr>1491828613491.JavaMail.zimbra@<wbr>cbs.mpg.de</a>><br>
Content-Type: text/plain; charset=utf-8<br>
<br>
Dear all,<br>
<br>
I'm trying to take age as a covariate into my cluster-based statistics comparing two dependent measures.<br>
<br>
I have read about two options:<br>
<br>
A) to use ft_regressconfound before I do the stats or<br>
B) to create a design with a third row using the .cvar field in the 'depsamplesregrT' statfun.<br>
<br>
I understand that for correcting head motions ft_regressconfound is a great option but for taking age into account as a covariate, it doesn't seem intuitive to me to do this within-subject on a trial-by-trial basis having only one number per person. Or can you use this function differently?<br>
<br>
However, for option B) the  subfunction 'unitselvec' is missing and this seems to be an issue for several years. So I was wondering whether anyone has ever tried to fix this problem themselves and wouldn't mind sharing?<br>
<br>
More generally, if anyone has successfully implemented a cluster-based statistics with one or more covariates, please share your experience, it would be greatly appreciated.<br>
<br>
Best Regards,<br>
Caroline<br>
<br>
--<br>
Caroline Beese<br>
PhD student<br>
<br>
Max-Planck Institute for Human Cognitive and Brain Sciences<br>
Department of Neuropsychology<br>
Stephanstr. 1a<br>
04103 Leipzig<br>
<br>
office phone: <a href="tel:%2B49%20%280%29%20341%209940%20129" value="+493419940129">+49 (0) 341 9940 129</a><br>
<br>
<a href="http://www.cbs.mpg.de/staff/beese-11586" rel="noreferrer" target="_blank">www.cbs.mpg.de/staff/beese-<wbr>11586</a><br>
<br>
<br></blockquote><div> </div></div></div></div></div></div></div></div>