<div dir="ltr">Hi Aaron (and all),<div><br></div><div>Sorry for the delayed reply; I had expected Fernando to take this one himself, but he's been bogged down with other duties.</div><div><br></div><div>The <font face="courier new, monospace">tckmap</font> command in the new MRtrix handles the whole generalised concept of track-weighted imaging (TWI). Track-weighted functional connectivity (TW-FC) is one particular application within this framework. The relevant options within <font face="courier new, monospace">tckmap</font> that you need to be aware of to duplicate the method as implemented in the TW-FC manuscript are as follows:</div>
<div><ul><li><font face="courier new, monospace">-contrast</font>: This specifies the type of image contrast that is assigned to each streamline. In the case of TW-FC, this contrast is drawn from an external image source; therefore you want to use <font face="courier new, monospace">scalar_map</font> as the value for this option.<br>
You must then also provide the path to this external image; this is done using the <font face="courier new, monospace">-image</font> option.<br>Note that this image does not necessarily have to be re-sampled to the same voxel grid as the diffusion images; it is adequate for the images to simply be aligned in real space, i.e. an anatomical location in the diffusion image maps to the same anatomical location in the associated scalar image, even if the image transforms / voxel sizes differ.</li>
<li><font face="courier new, monospace">-stat_vox</font>: This controls how the contributions to a voxel from multiple streamlines are combined into a single scalar value. In the TW-FC manuscript we used the <i>mean</i> value across all streamlines traversing each grid element.</li>
<li><font face="courier new, monospace">-stat_tck</font>: In cases where the selected form of image contrast may vary along the length of each streamline (which is the case for the <font face="courier new, monospace">scalar_map</font> contrast), this option controls how the values computed along the length of a streamline are combined to produce a single scalar value for that streamline. In the TW-FC manuscript, the <i>sum</i> of these values was used.</li>
</ul><div>The manuscript also described a method for masking out regions from the TW-FC map with unreliable values due to having too few streamlines traverse them. This can be achieved using something like:</div></div><div>
<br></div><div><font face="courier new, monospace">tckmap streamlines.tck - -template tw_fc.mif -contrast scalar_map_count -image tw_fc.mif | mrthreshold - - -abs 5 | mrcalc tw_fc.mif - -mult tw_fc_masked.mif</font></div>
<div><font face="courier new, monospace"><br></font></div><div><font face="arial, helvetica, sans-serif">In case you're not familiar with piping in MRtrix, the standalone '</font><font face="courier new, monospace">-</font><font face="arial, helvetica, sans-serif">' character indicates a temporary image that is to be passed from the output of one command to the input of another command, and the '</font><font face="courier new, monospace">|</font><font face="arial, helvetica, sans-serif">' character separates the commands.</font></div>
<div><font face="arial, helvetica, sans-serif">So in this case, there are three commands called in succession:</font></div><div><ol><li><font face="courier new, monospace">tckmap</font><font face="arial, helvetica, sans-serif">: Generate a track-weighted image where the contrast is simply a streamline count (i.e. TDI), but only those streamlines with a non-zero FC value contribute to the TDI;</font></li>
<li><font face="courier new, monospace">mrthreshold</font><span style="font-family:arial,helvetica,sans-serif">: Generate a binary mask image of those voxels traversed by at least 5 streamlines with non-zero FC value;</span></li>
<li><font face="courier new, monospace">mrcalc</font><span style="font-family:arial,helvetica,sans-serif">: Multiply the previously-calculated TW-FC map by this mask.</span><br></li></ol><div><font face="arial, helvetica, sans-serif">Have fun!</font></div>
</div><div><font face="arial, helvetica, sans-serif">Rob</font></div></div><div class="gmail_extra"><br clear="all"><div><div dir="ltr"><br>--<br><br><span style="color:rgb(255,102,0)"><b>Robert Smith, Ph.D</b><br>Research Officer, Imaging Division</span><br>
<br>The Florey Institute of Neuroscience and Mental Health<br>Melbourne Brain Centre - Austin Campus<br>245 Burgundy Street<br>Heidelberg Vic 3084<br>Ph: +61 3 9035 7128<br>Fax: +61 3 9035 7301<br><a href="http://www.florey.edu.au/" target="_blank">www.florey.edu.au</a><br>
</div></div>
<br><br><div class="gmail_quote">On Wed, May 28, 2014 at 6:41 AM, <a href="mailto:arswitze@ucalgary.ca">arswitze@ucalgary.ca</a> <span dir="ltr"><<a href="mailto:arswitze@ucalgary.ca" target="_blank">arswitze@ucalgary.ca</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello Romain,<br>
<br>
Thank you for your reply. Which option within in tckmap would I use to<br>
create a density volume that weights the tracks by a functional<br>
connectivity value? In other words, is there an option that could<br>
combine the tractogram with a functional connectivity map (transformed<br>
into diffusion space) where the sum of the functional connectivity<br>
values along a track would be calculated, and that sum would be<br>
assigned to the entire track. The final map would have a track weighted<br>
image that is weighted by the associated functional connectivity<br>
values. This method was outlined in this paper:<br>
<a href="http://www.sciencedirect.com/science/article/pii/S1053811912012402" target="_blank">http://www.sciencedirect.com/science/article/pii/S1053811912012402</a> but<br>
I have been unable to recreate it.<br>
<div class="HOEnZb"><div class="h5"><br>
Thank you for your help,<br>
Aaron<br>
<br>
> Le 27/05/2014 20:01, <a href="mailto:arswitze@ucalgary.ca">arswitze@ucalgary.ca</a> a écrit :<br>
>> Hello mrtrix community,<br>
>><br>
>> I am fairly new at mrtrix, and diffusion imaging in general, and I<br>
>> just had a question about the a command that is in mrtrix3. I am<br>
>> wondering if there is a way to perform track weighted imaging (TWI)<br>
>> using the newest build of mrtrix3. I was unable to find the command on<br>
>> the wiki, but in a previous discussion topic regarding the release of<br>
>> mrtrix3, it was mentioned that this version would include TWI<br>
>> functionality.<br>
>><br>
>> Thank you for your help,<br>
>> Aaron Switzer<br>
>><br>
>><br>
>> _______________________________________________<br>
>> Mrtrix-discussion mailing list<br>
>> <a href="mailto:Mrtrix-discussion@www.nitrc.org">Mrtrix-discussion@www.nitrc.org</a><br>
>> <a href="http://www.nitrc.org/mailman/listinfo/mrtrix-discussion" target="_blank">http://www.nitrc.org/mailman/listinfo/mrtrix-discussion</a><br>
>><br>
> Hello<br>
><br>
> this is the function tckmap that will transform your track into density<br>
> volume<br>
><br>
><br>
> _______________________________________________<br>
> Mrtrix-discussion mailing list<br>
> <a href="mailto:Mrtrix-discussion@www.nitrc.org">Mrtrix-discussion@www.nitrc.org</a><br>
> <a href="http://www.nitrc.org/mailman/listinfo/mrtrix-discussion" target="_blank">http://www.nitrc.org/mailman/listinfo/mrtrix-discussion</a><br>
><br>
><br>
><br>
<br>
<br>
_______________________________________________<br>
Mrtrix-discussion mailing list<br>
<a href="mailto:Mrtrix-discussion@www.nitrc.org">Mrtrix-discussion@www.nitrc.org</a><br>
<a href="http://www.nitrc.org/mailman/listinfo/mrtrix-discussion" target="_blank">http://www.nitrc.org/mailman/listinfo/mrtrix-discussion</a><br>
</div></div></blockquote></div><br></div>