<div dir="ltr">Dear all,<div><br></div><div>I have a question concerning <span style="color:rgb(0,0,0)">the usage of ft_sourcegrandaverage and ft_sourcestatistics. </span></div><div><font color="#000000"><br></font></div><div>
<font color="#000000">After using ft_sourceanalysis (method: MNE), I get spatio-temporal source reconstructed data in source.avg.pow (4050 x 897): 4050 sources and 897 time points. </font></div><div><font color="#000000"><br>
</font></div><div><font color="#000000">Now I would like to use the cluster-based permutation test on my source reconstructed data. However it seems like ft_sourcegrandaverage and</font><span style="color:rgb(0,0,0)"> ft_sourcestatistics don't support source level time courses. E.g when I am using </span><span style="color:rgb(0,0,0)">ft_sourcegrandaverage I am getting the following error:</span></div>
<div><font color="#000000"><br></font></div><div><div>Error in ft_sourcegrandaverage (line 158)</div><div> dat(:,i) = tmp(:);</div><div><br></div><div style>Looking into the code:</div><div style><br></div><div style><p style="margin:0px;font-size:10px;font-family:Courier">
<span style="color:rgb(4,51,255)">for</span> i=1:Nsubject</p>
<p style="margin:0px;font-size:10px;font-family:Courier"> tmp = getsubfield(varargin{i}, parameterselection(cfg.parameter, varargin{i}));</p>
<p style="margin:0px;font-size:10px;font-family:Courier"> dat(:,i) = tmp(:);</p>
<p style="margin:0px;font-size:10px;font-family:Courier"> tmp = getsubfield(varargin{i}, <span style="color:rgb(178,69,243)">'inside'</span>);</p>
<p style="margin:0px;font-size:10px;font-family:Courier"> inside(tmp,i) = 1;</p>
<p style="margin:0px;font-size:10px;font-family:Courier;color:rgb(4,51,255)"><span style="color:rgb(0,0,0)"> </span>end</p><div><br></div></div><div style>I see that "tmp" are getting the structure [N_sources x timepoints] from source.avg.pow for one subject, where "dat" requires the structure [N_sources x 1]. <br>
</div><div style><br></div><div style>I seached the mailing list for similar issues and found this thread:</div><div style><br></div><div style><a href="http://mailman.science.ru.nl/pipermail/fieldtrip/2010-September/003122.html">http://mailman.science.ru.nl/pipermail/fieldtrip/2010-September/003122.html</a><br>
</div><div style><br></div><div style>Since I am interested in using the temporal dimension in my statistics, I would like to know if it is still not possible to use spatio-temporal source reconstructed data in ft_sourcestatistics and ft_sourcegrandaverage ?</div>
<div style><br></div><div style>Or if any have succeeded in using the cluster-based permutation test on source level also including the temporal dimension ? </div><div style><br></div><div style>Alternative I was thinking that I might could use ft_timelockstatistics, where I substituted the channels with sources, e.g instead of having 64 channels, I would now have 4050 "channels". </div>
<div style>If so I need to calculate a label structure and an appropriate neighbor structure, which I guess is possible as I have all the 3D coordinates for each source, e.g in leadfield.pos ?</div><div style>I know this is a work around solution, but have anyone tried or have any experience using such an approach ? </div>
<div style><br></div><div style>Best,</div><div style><br></div><div style>Nicolai</div><div><br></div></div></div>