Code covered by the BSD License  

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

Highlights from
DTI and Fiber Tracking

3.9 | 8 ratings Rate this file 35 Downloads (last 30 days) File Size: 5.05 MB File ID: #21130 Version: 1.0
image thumbnail

DTI and Fiber Tracking


Dirk-Jan Kroon (view profile)


19 Aug 2008 (Updated )

Diffusion MRI (DTI), calculates FA, ADC, Vector Field, and will track and visualize neural tracts.

| Watch this File

File Information

Straightforward Diffusion MRI (DTI) and Fiber Tracking (FT) functions and examples.

DTI.m, will calculate the Apparent Diffusion Coefficient(ADC), fractional anistropy (FA), and diffusion tensor field, of a DTI datasets consisting of at least 6 dataset with different MRI gradients and at least 1 without gradient.

FT.m, will calculate neural tracts (fiber tracts) starting from every point in the brain, and outputs all fibers crossing a certain ROI.

Try DTI_example.m and then FT_example.m


This file inspired Extended Version Of Ft.M Func Of File Id: #21130.

Required Products Image Processing Toolbox
MATLAB release MATLAB 7.6 (R2008a)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (17)
09 Dec 2014 RÜZGAR YANIK

firstly thanks share this code with us

i have a problem in part of code

FT(FA,VectorF,Roi,parameters) in FT.m

How we take "Roi Parameter" in different image

if someone knows, kindly help me about this topic

Comment only
26 Sep 2012 StudentResearch

First of all, thank you very much for sharing your code.

I have just the same question as M :

- Is there any reference or paper published of this fiber tracking method?

-It is a new method or is a known tracktography algorithm?

25 Mar 2012 M

M (view profile)

Is there any reference or paper published of this fiber tracking method?
It is a new method or is a known tracktography algorithm like the S. Mori approach?

25 Mar 2012 M

M (view profile)

In the help note for DTI function we see: DifT: A 3D matrix ... should it be 4D matrix?

Comment only
17 Aug 2011 Bunheang Tay

hi all, I know this code is work with gipl format. I have used with hdr, and img, it just fine.
I wonder whether it works accurate or not?

it is a nice work, thank!

20 May 2011 Shripad Kondra  
07 Sep 2009 Alper Yaman

In FT.m line 41 should be "fiber=zeros(parameters.FiberLengthMax,3);" not "fiber=zeros(600,3);".

Comment only
04 Jun 2009 k m

k m (view profile)

Is this code working with only gipl format? I have been using .img files, but the results seem to be now good. Is any body there who has similar question?


Comment only
01 Jun 2009 k m

k m (view profile)

Is anybody there who used this code with phantom data rather than human data?

Comment only
08 Apr 2009 Alper Yaman

You may also change stepsize to a 1x3 vector, each element increments fiber by different scales for anisotropic image sets.

Comment only
05 Apr 2009 Alper Yaman

Thank you for codes. For smoothing, you may use 2 approach:
1. Smooth images before all calculations.
2. Convert eigenvectors to spherical coordinates and smooth r,theta and phi seperately. I am not sure, but it will better than smoothing in cartesian coordinates.

04 Apr 2009 Eric Candelabro

Is there any reference or paper published of this fiber tracking method?
It is a new method or is a known tracktography algorithm like the S. Mori approach?

Comment only
30 Mar 2009 smitha mahesh

can I use it for 30 directions

27 Nov 2008 Dirk-Jan Kroon

Dirk-Jan Kroon (view profile)

I detected an error in the fiber tracking function when working on a version which could detect crossing and fiber splittings.

The smoothing of the vector/tensor field in FT.m, may not be done in this way: VectorF(:,:,:,1)=imfilter(VectorF(:,:,:,1),fspecial3('gaussian',[4 4 4]));
because a DTI vector is equal to a DTI vector pointing in the exact oppositie direction. With simple gaussian smoothing they will cancel each other out, which we don't want.

You can fix the function by removing the smoothing.

I hope to replace this smoothing with another smoothing algorithm, next file update.

Comment only
16 Sep 2008 Dirk-Jan Kroon

*Jerod Rasmussen
The method works also for 10 or 12 directions, in fact I use this function for more then 30 gradient directions in Dicom formatted 3D data.

The DTI_example is only an simple example! of how you can use the DTI function...

Comment only
12 Sep 2008 Jerod Rasmussen

Requires an obscure file format, as is only works on 6 directional, but nice place to start a DTI function.

19 Aug 2008 jichao zhao

It is excellent work. thanks for sharing

Contact us