<div dir="ltr"><div dir="ltr"><div>Hello, one last email just in case anyone is following my series of very silly questions or ever searches the following warnings when trying to run ft_timelockstatistics:<br></div><div></div><div><pre>Warning: timelock structure contains field with and without repetitions<br><br>Error: the length of the design matrix does not match the number of observations in the data<br></pre><div>In my case, it was because, in the previous step where I averaged ERPs over trials using ft_timelockanalysis, I had set cfg.keeptrials = 'yes' . It should be left at the default 'no' (for a within-subjects design at least), otherwise ft_timelockstatistics will go looking for observations in the wrong spot (trial) and will discard the ones it really needs (avg, var, dof).</div><div><br></div><div>Thanks and apologies for over-posting,</div><div>Kate<br></div></div></div></div><br><div class="gmail_quote"><div dir="ltr">On Tue, Oct 23, 2018 at 5:21 PM Kate Stone <<a href="mailto:katemsto@gmail.com">katemsto@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Hi again,</div><div><br></div><div>Further to the below, what I would actually prefer to do is use the depsamplesT test on my data structure containing averages over trials for each subject (i.e. the output of ft_timelockanalysis).</div><div><br></div><div>But every time I try, I get the message "length of the design matrix (2) doesn't equal the number of observations (694)" - no matter what the dimensions of the design matrix are. I've set up the matrix exactly as specified in the tutorial (relevant to my data of course). Any idea what this error is about? <br></div><div><br></div><div>Thanks again,<br></div><div>Kate<br></div><div><br><div class="gmail_quote"><div dir="ltr">On Tue, Oct 23, 2018 at 2:04 PM Kate Stone <<a href="mailto:katemsto@gmail.com" target="_blank">katemsto@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div>Hi all,</div><div><br></div><div>I've been following the tutorial here to do a time-locked perm test on ERP data: <a href="http://www.fieldtriptoolbox.org/tutorial/cluster_permutation_timelock" target="_blank">www.fieldtriptoolbox.org/tutorial/cluster_permutation_timelock</a></div><div><br></div><div>I have computed grand averages for my two conditions and am using indepsamplesT with ft_timelockstatistics(cfg, GA_1, GA_2).</div><div><br></div><div>But what should the design matrix be? The example in the tutorial doesn't apply as I am using grand averages and the reference for ft_timelockstatistics doesn't mention the design matrix, although it is definitely required. I have tried design = [1,2], but this doesn't seem to give sensible results. <br></div><div><br></div><div>Thanks in advance,</div><div>Kate<br></div><div><div><br><br></div></div></div></div></div>
</blockquote></div><br clear="all"><br>-- <br><div dir="ltr" class="m_8537768940253419618gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><span><font color="#888888"><div><div><div><div>Kate Stone<br></div>PhD candidate<br></div>Vasishth Lab | Department of Linguistics<br></div>Potsdam University, 14467 Potsdam, Germany<br></div><a href="https://auskate.github.io" target="_blank">https://auskate.github.io</a></font></span></div></div></div></div>
</blockquote></div><br clear="all"><br>-- <br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><span><font color="#888888"><div><div><div><div>Kate Stone<br></div>PhD candidate<br></div>Vasishth Lab | Department of Linguistics<br></div>Potsdam University, 14467 Potsdam, Germany<br></div><a href="https://auskate.github.io" target="_blank">https://auskate.github.io</a></font></span></div></div>