Content-type: text/html
This program computes statistics from streamline tracts, either using the tracts themselves or using the values of a scalar image along the streamline.
Tract scalar statistics are computed by evaluating a scalar image along the length of the streamline, and returning some function of the scalar values. The scalar image should be defined in the same space as the streamlines.
Some definitions
T - a streamline containing points T(1)...T(N).
l - the length of the streamline.
S(T) - a vector of scalar values computed by evaluating the scalar image at each point in T.
The tract statistic may be either the mean, sum, minimum, maximum, median, or variance of S(T), the values at each point along the streamline. The option "meanvar" returns both the mean and variance.
Interpolation in the context of this program means linearly interpolating the image data. The image intensity is evaluated at each point in T.
The assumption here is that the points on T are approximately evenly sampled. If T was defined using a fixed step size algorithm (-interpolated passed to track) then the distance between points will be equal, which is optimum for estimating the mean image value along T. If the step size is variable, for example in FACT, then the points on T are not evenly sampled, which introduces a bias. By default, raw streamlines are resampled to a resolution of 0.1 mm, which will reduce the bias. Voxel lists are not resampled by default; the image intensity is sampled once at the centre of each voxel intersected by the streamline.
Non image-based statistics use information embedded in the streamlines themselves. Currently, the only statistic of this kind is the streamline length, l.
The output is the tract statistic for each streamline sent to the image, in the order in which they are read from the input.
Track in an ROI and get the mean FA along each tract.
cat SubjectA.oneDT.Bdouble | track -inputmodel dt -seedfile subAROI.hdr
-interpolate vectors -stepsize 0.5 -anisthresh 0.1 | tractstats -tractstat mean
-interpolate -scalarfile fa.hdr > tractMeanFA.Bdouble
Get the minimum mean diffusivity along the tracts
cat SubjectA.oneDT.Bdouble | track -inputmodel dt -seedfile subAROI.hdr
-interpolate vectors -stepsize 0.5 -anisthresh 0.1 | tractstats -tractstat min
-interpolate -scalarfile md.hdr > tractMinMD.Bdouble
This is new code, the implementation / interface may change.