All Functions
All Functions
In[28]:= QMRIToolsFunctions[50]
Functions
2 All-Functions.nb
Options
4 All-Functions.nb
In[24]:= QMRIToolsFunctions["All", 8]
CardiacTools
Functions
BullseyePlot HelixAngleCalc
CalculateWallMap MakeECVBloodMask
CardiacCoordinateSystem MaskHelix
CardiacSegment PlotSegmentMask
CentralAxes PlotSegments
CreateHeart RadialSample
ECVCalc TransmuralPlot
ExcludeSlices
Options
AxesMethod GridLineSpacing PlotLabel StartPoints
BackgroundValue HelixMethod PlotRange StartSlices
BloodMaskRange ImageSize PlotStyle TextOffset
BullPlotMethod LineStep RadialSamples TextSize
ColorFunction LineThreshold RowSize
CutOffMethod MaskWallMap ShowFit
DistanceMeasure Method ShowHelixPlot
DropSamples OutputCheckImage SmoothHelix
6 All-Functions.nb
CoilTools
Functions
CoilSNRCalc NoiseCovariance
FindCoilPosition
LoadCoilSetup
LoadCoilTarget
MakeCoilLayout
MakeNoisePlots
MakeWeightMask
NoiseCorrelation
Options
CoilArrayPlot
CoilSurfaceVoxelSize
ColorFunction
ImageSize
OutputCoilSurface
PlotRange
DenoiseTools
Functions
AnisoFilterTensor
DeNoise
PCADeNoise
PCAFitEq
PCAFitHist
WeightMapCalc
Options
AnisoFilterSteps Method
AnisoKappa PCAFitParameters
AnisoStepTime PCAKernel
AnisoWeightType PCAOutput
DeNoiseIterations PCATollerance
DeNoiseKernel PCAWeighting
DeNoiseMonitor PlotSolution
FitSigma
All-Functions.nb 7
DixonTools
Functions
DixonReconstruct
DixonToPercent
SimulateDixonSignal
Unwrap
UnwrapSplit
Options
DixonAmplitudes DixonPrecessions
DixonFieldStrength DixonTollerance
DixonFilterInput MonitorUnwrap
DixonFilterOutput UnwrapDimension
DixonFilterSize
DixonFrequencies
DixonIterations
DixonMaskThreshhold
ElastixTools
Functions
ReadTransformParameters TransformData
RegisterCardiacData
RegisterData
RegisterDataSplit
RegisterDataTransform
RegisterDataTransformSplit
RegisterDiffusionData
RegisterDiffusionDataSplit
Options
AffineDirections InterpolationOrderRegA OutputTransformation UseGPU
BsplineDirections Iterations PCAComponents
BsplineSpacing IterationsA PrintTempDirectory
DeleteTempDirectory MethodReg RegistrationTarget
FindTransform MethodRegA Resolutions
HistogramBins NumberSamples ResolutionsA
HistogramBinsA NumberSamplesA SplitMethod
InterpolationOrderReg OutputImage TempDirectory
8 All-Functions.nb
GeneralTools
Functions
ApplyCrop DevideNoZero LogNoZero QMRIToolsFunctions SumOfSquares
AutoCropData ExpNoZero MADNoZero QMRIToolsPackages TensMat
ClearTemporaryVariables FileSelect MeanNoZero RescaleData TensVec
CompilebleFunctions FindCrop MedianNoZero ReverseCrop TransData
CropData FindMaxDimensions MemoryUsage RMSNoZero VectorToData
CutData GridData NNLeastSquares SaveImage
Data2DToVector GridData3D PadToDimensions StdFilter
Data3DToVector LapFilter QMRIToolsFuncPrint StichData
Options
CropInit PadDirection
CropOutput PadValue
CropPadding WindowTitle
FileType
ImageResolution
ImageSize
InterpolationOrder
OutputWeights
All-Functions.nb 9
GradientTools
Functions
Bmatrix ConvertGrads GenerateGradientsGUI UniqueBvalPosition
BmatrixCalc CorrectBmatrix GetGradientScanOrder
BmatrixConv CorrectGradients GetSliceNormal
BmatrixInv EnergyCalc GetSliceNormalDir
BmatrixRot FinalGrads GradBmatrix
BmatrixToggle FindOrder GradSeq
CalculateMoments FullGrad ImportGradObj
ConditionNumberCalc GenerateGradients OverPlusCalc
Options
ConditionCalc OutputPlot UseGrad
FlipAxes OutputType VisualOpt
FlipGrad PhaseEncoding
FullSphere Runs
GradType Steps
Method StepSizeI
MethodReg SwitchAxes
OrderSpan UnitMulti
ImportTools
Functions
BvalRead ReadGradients
GradRead ReadVoxSize
ReadBrukerDiff ShiftPar
ReadBvalue
ReadDicom
ReadDicomDiff
ReadDicomDir
ReadDicomDirDiff
Options
BmatrixOut
ConvertDcm
RotateGradient
ScaleCorrect
10 All-Functions.nb
IVIMTools
Functions
BayesianIVIMFit2 IVIMCorrectData
BayesianIVIMFit3 IVIMFunction
CorrectParMap IVIMResiduals
FConvert ThetaConv
FConverti ThetaConvi
FracCorrect
HistogramPar
IVIMCalc
Options
ChainSteps IVIMComponents Parallelize
CorrectPar IVIMConstrained UpdateStep
FilterMaps IVIMConstrains
FilterSize IVIMFixed
FilterType IVIMTensFit
FitConstrains Method
FixPseudoDiff MonitorIVIMCalc
FixPseudoDiffSD OutputSamples
All-Functions.nb 11
JcouplingTools
Functions
GetSpinSystem SimEvolve
PhaseAlign SimHamiltonian
PlotSpectrum SimReadout
SequencePulseAcquire SimRotate
SequenceSpinEcho SimSignal
SequenceSteam SimSpoil
SequenceTSE SysTable
SimAddPhase
Options
CenterFrequency ReadoutSamples
FieldStrength SpectrumColor
Linewidth
LinewidthShape
PlotRange
ReadoutBandwith
ReadoutOutput
ReadoutPhase
MaskingTools
Functions
GetMaskData RescaleSegmentation
HomoginizeData ROIMask
Mask SegmentMask
MaskData SmoothMask
MeanSignal SmoothSegmentation
MergeSegmentations SplitSegmentations
NormalizeData
RemoveMaskOverlaps
Options
GetMaskOutput
MaskClosing
MaskComponents
MaskFiltKernel
MaskSmoothing
UseMask
12 All-Functions.nb
NiftiTools
Functions
CompressNiiFiles ImportBval ImportNiiT2
DcmToNii ImportBvalvec
ExportBmat ImportBvec
ExportBval ImportExploreDTItens
ExportBvec ImportNii
ExportNii ImportNiiDiff
ExtractNiiFiles ImportNiiDix
ImportBmat ImportNiiT1
Options
CompressNii
FlipBvec
Method
NiiDataType
NiiMethod
NiiScaling
RotateGradients
PhysiologyTools
Functions
AlignRespLog
ImportPhyslog
ImportRespirect
PlotPhyslog
PlotRespiract
Options
OutputMethod
SampleStep
All-Functions.nb 13
PlottingTools
Functions
GetSliceData PlotData3D
GetSlicePositions PlotDefGrid
GradientPlot PlotDuty
ListSpherePlot PlotIVIM
MakeSliceImages PlotMoments
PlotContour PlotSequence
PlotCorrection
PlotData
Options
ColorFunction PeakNumber
ContourStyle PlotColor
DropSlices PlotRange
ImageLegend PlotSpace
ImageSize PositiveZ
MakeCheckPlot SphereColor
Method SphereSize
NormalizeIVIM
14 All-Functions.nb
ProcessingTools
Functions
CorrectJoinSetMotion FitData MedCouple SplitSets
DataTransformation GetMaskMeans NumberTableForm
DatTot Hist ParameterFit
DatTotXLS Hist2 ParameterFit2
ErrorPlot InvertDataset SetupDataStructure
FiberDensityMap JoinSets SmartMask
FiberLengths MeanRange SNRCalc
FindOutliers MeanStd SNRMapCalc
Options
AxesLabel MeanMethod OutlierRange SmartMaskOutput TableMethod
ColorValue Method OutputSNR SmartMethod TableSpacing
FitFunction MotionCorrectSets PaddOverlap SmoothSNR
FitOutput NormalizeSets PlotLabel Strictness
ImageSize OutlierIncludeZero ReverseData TableAlignments
InterpolationOrder OutlierIterations ReverseSets TableDepth
JoinSetSplit OutlierMethod Scaling TableDirections
MaskCompartment OutlierOutput SeedDensity TableHeadings
All-Functions.nb 15
RelaxometryTools
Functions
CalibrateEPGT2Fit T2Fit
CreateT2Dictionary TriExponentialT2Fit
DictionaryMinSearch
EPGSignal
EPGT2Fit
NonLinearEPGFit
T1Fit
T1rhoFit
Options
DictB1Range Method
DictT2fRange MonitorEPGFit
DictT2Range OutputCalibration
EPGCalibrate
EPGFitPoints
EPGMethod
EPGRelaxPars
EPGSmoothB1
16 All-Functions.nb
SimulationTools
Functions
AddNoise PlotSimulationAngleHist Tensor
BlochSeries PlotSimulationHist
CalculateGfactor PlotSimulationVec
CreateDiffData Pulses
GetPulseProfile Signal
GfactorSimulation SimAngleParameters
PlotSimulation SimParameters
PlotSimulationAngle SimulateSliceEPG
Options
GOutput SliceRangeSamples
GRegularization SortVecs
MagnetizationVector TensOutput
NoiseSize
PlotRange
Reject
ReportFits
SliceRange
All-Functions.nb 17
TensorTools
Functions
ADCCalc ECalc SigmaCalc
AngleCalc EigensysCalc SortDiffusionData
AngleMap EigenvalCalc TensorCalc
ColorFAPlot EigenvecCalc TensorCorrect
ConcatenateDiffusionData FACalc
Correct ParameterCalc
Deriv RemoveIsoImages
DriftCorrect ResidualCalc
Options
Distribution Reject
FilterShape RejectMap
FullOutput RobustFit
MeanRes RobustFitParameters
Method RotationCorrect
MonitorCalc UseMask
NormalizeSignal
Parallelize
VisteTools
Functions
DatRead ImportVol
DatWrite LoadFiberTracts
DTItoolExp
DTItoolExpFile
DTItoolExpInd
DTItoolExpTens
ExportVol
ImportDTI
Options
BinaryType
In[25]:= QMRIToolsFuncPrint[]
CardiacTools
18 All-Functions.nb
Functions
Output is a bullseye plot or a plotwindow, depending on the Method which can be "Dynamic" else it will be static.
Options[BullseyePlot] =
TextOffset → 0.5, TextSize → 12, PlotRange → Automatic, ColorFunction → TemperatureMap, BullPlotMethod → Dynamic, ImageSize → 200
CalculateWallMap[mask,vox] calculates the wall distance map and the wall derivative.
CardiacCoordinateSystem[mask, vox] creates the cardiac coordinate system within the mask.
output is a set of vectors {radvecn, norvecc, cirvec}, being the radial, normal and circular axes of each voxel respectivley.
All-Functions.nb 19
CardiacSegment[data, mask, off] allows to segment the heart in 1, 4, 6 or AHA-17 segements for each slice 360 radial samples are generated.
CentralAxes[mask, vox] calculates the center of the lumen from a mask of the left ventricle. vox is the voxels size, {slice, x, y}.
CentralAxes[mask, maskp, vox] allows for fancy visualization of the other structures using maskp.
Output is the heart shape, the voxel size and the parameters needed to generate the heart, {mask, vox, pars}.
ExcludeSlices[data] excludes slices that do not look like the others based on various distance measures.
HelixAngleCalc[eigenvectors, mask, vox] calculates the helix angle matrix of cardiac data using only a left ventricle mask.
HelixAngleCalc[eigenvectors, mask, vox] calculates
the helix angle matrix of cardiac data using only a left ventricle mask, and a maskp for visualization.
HelixAngleCalc[eigenvectors, mask, centerpoint, vec, inout, vox] calculates the helix angle matrix of cardiac data using only a left ventricle mask.
HelixAngleCalc[eigenvectors, mask, maskp, centerpoint, vec, inout, vox]
calculates the helix angle matrix of cardiac data using a left vantricle mask and a maskp for visualization.
The folowing values are calculated automaticlay Using CentralAxes but can also be provided as an input.
centerpoint is the center of each slice calculated with CentralAxes.
inout is the inner and outer radius calcualted with CentralAxes.
vec is the vector describin the central axes of the heart, calculated with CentralAxes.
Output is het fiber angle matrix FAM = {9, slice, x, y} or {FAM, plot}.
MaskHelix[helix, mask] masks helix angle data, sets the background to -100 and allows for Median filter of the helix mask.
helix can be a singel map or the FAM.
mask is a mask the left ventricle that was used in the CardiacSegment.
segmask is the output of CardiacSegemnt.
vox is the voxels size, {slice, x, y}.
PlotSegments[mask, data, segang] shows how the heart wil be sampled by RadialSample.
mask is a mask the left ventricle that was used in the CardiacSegment.
function and the segang is the output of the cardaic SegmentFunction.
The mask should be a mask of the left ventricle that was used in the CardiacSegment.
segang is the output of the cardaic SegmentFunction.
TransmuralPlot[data] plots transmural profiles of the data which are created by RadialSample.
data can be a single profile or a list of profiles. In the second case the mean and standardeviations are plotted.
Options[TransmuralPlot] =
GridLineSpacing → 10, PlotStyle → RGBColor[1, 0, 0], PlotRange → Automatic, ImageSize → 300, Method → Median, PlotLabel → None
Options
AxesMethod is an option for HelixAngleCalc and CentralAxes. Can be "Linear", "Quadratic", "Cubic".
BackgroundValue is an option for MaskHelix. Sets the backgroud value (default is -100).
ColorFunction is an option for graphics functions that specifies a function to apply to determine colors of elements.
AttributesColorFunction = {Protected}
CutOffMethod is an option for ExcludeSlices. Default value is "Auto" or it can be a fixed percentage (value between 0 and .5)
ImageSize is an option that specifies the overall size of an image to display for an object.
AttributesImageSize = {Protected}
LineThreshold is an option for CardiacSegment. Can be number between 0 and 1. Increasing the value will decrease the amount of wall sampled.
Method is an option for various algorithm-intensive functions that specifies what internal methods they should use.
Attributes[Method] = {Protected}
QMRITools`CardiacTools`OutputCheckImage
PlotLabel is an option for graphics functions that specifies an overall label for a plot.
Attributes[PlotLabel] = {Protected}
PlotRange is an option for graphics functions that specifies what range of coordinates to include in a plot.
PlotStyle is an option for plotting and related functions that specifies styles in which objects are to be drawn.
Attributes[PlotStyle] = {Protected}
RadialSamples is an option for RadialSample and PlotSegments. Defines how manny transmural samples are taken.
RowSize is an option for CentralAxes. defines the number or images per showing the segmentation.
Can be "Automatic" of an integer.
ShowFit is an option for CentralAxes. True shows the fit of the central axes.
ShowHelixPlot is an option for HelixAngleCalc. If true the it also outputs a visulization of the local myocardial coordinate system.
SmoothHelix is an option for MaskHelix, sets the kernelsize for the MedianFilter.
StartPoints is an option for CardiacSegment. Value is "Default" or the point list given by CardiacSegment.
StartSlices is an option for CardiacSegment. Value is "Default" or the list given by CardiacSegment.
TextOffset is an option for BullseyePlot. Determines where the text is placed, can be 0 to 1.
CoilTools
Functions
CoilSNRCalc[coils, noise] calculates the sensitivity weighted snr of multiple coil elements using magnitude signal and noise.
LoadCoilSetup[file] load a very specific type of coil experiment, a dynmic scan with a setup of which the second dynamic is a noise measurement.
The input file is the Nii file that conatins the individualy reconstruted coil images and the noise data.
Internaly it uses CoilSNRCalc and SumOfSquares.
Output is the coil data with coil noise data and snrmap based on the SumOfSquares addition, the SOS reconstruction and the SOS weights.
{dataC, noiseC, sosC, snrC, sigmapC, weights, vox}.
28 All-Functions.nb
LoadCoilTarget[file] loads a very specific typ of experiment, a dynamic scan with with the second dynmaic is a noise measuremnt.
The input file is the Nii file that conatins the scanner reconstruction and the noise data.
Internaly it uses SNRMapCalc,
Output is the reconstructed data with noise data and snrMap {dataC, noiseC, sosC, snrC, sigmapC, weights, vox}.
MakeCoilLayout[{name, size, number}] makes a coil grid with label name, partioned in size rows and with label number.
MakeCoilLayout[{name, size, number}, val] makes a coil grid with label name, partioned in size rows and with label the val at location number.
MakeCoilLayout[{coils..}] same but for multile coils grids. Each coil grid is defined as {name, size, number}.
MakeCoilLayout[{coils..}, val] savem but for multiple coil grids.
NoiseCorrelation[noise] calculates the noise correlation matrix, noise is {nrCoils, noise Samples}.
NoiseCovariance[noise] calculates the noise covariance matrix, noise is {nrCoils, noise Samples}.
Options
CoilArrayPlot is an option for MakeCoilLayout. If True and values are provided it makes an arrayplot of the coil layouts
CoilSurfaceVoxelSize is an option for FindCoilPosition. Specifies the voxel size used for OutputCoilSurface.
ColorFunction is an option for graphics functions that specifies a function to apply to determine colors of elements.
AttributesColorFunction = {Protected}
ImageSize is an option that specifies the overall size of an image to display for an object.
AttributesImageSize = {Protected}
OutputCoilSurface is an option for FindCoilPosition. If set true it will also output a SurfacePlot of the coil location volume.
PlotRange is an option for graphics functions that specifies what range of coordinates to include in a plot.
DenoiseTools
Functions
AnisoFilterTensor[tens, diffdata] Filter the tensor tens using an anisotropic diffusion filter (Perona-Malik).
It uses the diffusion weighted data diffdata to find edges that are not visible in the tensor.
Edge weights based on the diffusion data are averaged over all normalized diffusion direction.
Output is de {data denoise, sigma map} by default if PCAOutput is Full then fitted {data dnoise , {sigma
fit, average sigma}, {number components, number of fitted voxesl, number of max fits}, total fit -time per 500 ittt}.
OptionsPCADeNoise =
PCAKernel → 5, PCAFitParameters → {10, 6, 10}, FitSigma → False, PCAOutput → Full, Method → Equation, PCATollerance → 0, PCAWeighting → True
PCAFitEq[data] fits the marchencopasteur distribution to the PCA of the data using grid search.
PCAFitEq[data, sig] fits the marchencopasteur distribution to the PCA of the data using sig as start value or fixed value using grid search.
PCAFitHist[data] fits the marchencopasteur distribution to the PCA of the data using hist fit.
PCAFitHist[data, sig] fits the marchencopasteur distribution to the PCA of the data using sig as start value or fixed value using hist fit.
Output is a weight map of the diffdata which is high in isotropic regions and low at edges.
Options
AnisoFilterSteps is an option for AnisoFilterTensor and defines the amoutn of diffusin steps taken. Higher is more smoothing
AnisoKappa is an option for AnisoFilterTensor and WeightMapCalc and defines the weighting strenght, all data is normalize to 100 before filetering.
AnisoStepTime is an option for AnisoFilterTensor and defines the diffusion time, when small more step are needed.
DeNoiseIterations is and option for DeNoise. Specifies the number of the denoising iterations.
DeNoiseKernel is and option for DeNoise. Values can be "Disk", "Box" or "Gaussian".
FitSigma is an option of PCAFitHist, PCAFitEq and PCADeNoise, if set True sig is fitted if set False sigma is fixed to input value.
Method is an option for various algorithm-intensive functions that specifies what internal methods they should use.
Attributes[Method] = {Protected}
PCAFitParameters is an option of PCADeNoise and PCAFitHist. {nb, pi, maxit} = bins, initial signal components, maximum number of itterations.
PCAOutput is an option of PCADeNoise. If output is full the output is {datao, {output[[1]], sigmat}, {output[[2]], output[[3]], j}, timetot}.
Else the output is {datao, sigmat}.
PCATollerance is an option of PCADeNoise and shuld be an integer > 0. Default value is 0. When increased the denoise method removes less noise.
PCAWeighting is an option of PCADeNoise and can be True of False. Default value is False.
When True the weights of the per voxel result are calculated based on the number of non noise components.
PlotSolution is an option for PCAFitHist, if set true it dispays the fitting itterations.
DixonTools
Functions
DixonReconstruct[real, imag, echo] reconstruxt Dixon data with initital guess b0 = 0 and T2star = 0.
DixonReconstruct[real, imag, echo, b0] reconstructs Dixon data with intitial guess T2star = 0.
DixonReconstruct[real, imag, echo, b0, t2] reconstructs Dixon data.
Output is {{watF,fatF},{watSig,fatSig},{inphase,outphase},{B0,T2star},itterations}.
OptionsDixonReconstruct =
DixonPrecessions → -1, DixonFieldStrength → 3, DixonFrequencies → {{0}, {3.8, 3.4, 3.13, 2.67, 2.46, 1.92, 0.57, -0.6}},
DixonAmplitudes → {{1}, {0.089, 0.598, 0.047, 0.077, 0.052, 0.011, 0.035, 0.066}}, DixonIterations → 5,
DixonTollerance → 0.01, DixonMaskThreshhold → 0.05, DixonFilterInput → True, DixonFilterOutput → True, DixonFilterSize → 1
DixonToPercent[water, fat] converts the dixon water and fat data to percent maps.
OptionsSimulateDixonSignal =
DixonPrecessions → -1, DixonFieldStrength → 3, DixonFrequencies → {{0}, {3.8, 3.4, 3.13, 2.67, 2.46, 1.92, 0.57, -0.6}},
DixonAmplitudes → {{1}, {0.089, 0.598, 0.047, 0.077, 0.052, 0.011, 0.035, 0.066}}
OptionsUnwrapSplit = {}
Options
DixonAmplitudes is an options for DixonReconstruct. Defines the amplitudes of the fat peaks being used.
36 All-Functions.nb
DixonFieldStrength is an options for DixonReconstruct. Defines the fieldstrengths on which the data was acquired.
DixonFilterInput is an options for DixonReconstruct. If True the input b0 and T2star values are smoothed using a gaussian kernel.
DixonFilterSize is an options for DixonReconstruct. Defines the number of voxel with which the input b0 and T2star values are smoothed.
DixonFrequencies is an options for DixonReconstruct. Defines the frequencies of the fat peaks being used.
DixonIterations is an options for DixonReconstruct. Defines the maximum itterations the fit can use.
DixonPrecessions is an options for DixonReconstruct. Defines the rotation of the signal {-1,1} default is -1.
UnwrapDimension is an option for Unwrap. Can be "2D" or "3D". 2D is for unwarpping 2D images or unwrapping the
individual images from a 3D dataset (does not unwrap in the slice direction). 3D unwraps a 3D dataset in all dimensions.
ElastixTools
Functions
RegisterData[{target, mask}, moving] registers the data series only using data whithin the mask.
RegisterData[target, {moving, mask}] registers the data series only using data whithin the mask.
RegisterData[{target, mask}, moving] registers the data series only using data whithin the mask.
RegisterData[{target, mask}, {moving, mask}] registers the data series only using data whithin the mask.
RegisterData[target, {moving, mask, vox}] registers the data series using the given voxel size only using data within the mask.
RegisterData[{target, mask}, {moving, mask, vox}] registers the data series using the given voxel size only using data within the mask.
RegisterData[{target, vox}, {moving, mask, vox}] registers the data series using the given voxel size only using data within the mask.
RegisterData[{target, mask, vox}, moving] registers the data series using the given voxel size only using data within the mask.
RegisterData[{target, mask, vox}, {moving, mask}] registers the data series using the given voxel size only using data within the mask.
All-Functions.nb 39
RegisterData[{target, mask, vox}, {moving, vox}] registers the data series using the given voxel size only using data within the mask.
RegisterData[{target, mask}, {moving, vox}] registers the data series using the given voxel size only using data within the mask.
RegisterData[{target, vox}, {moving, mask}] registers the data series using the given voxel size only using data within the mask.
Output is the registered data with the dimensions of the moving data.
If OutputTransformation is True it also outputs the translation, rotation scale and skew of all images or volumes.
OptionsRegisterData =
Iterations → 250, Resolutions → 1, HistogramBins → 64, NumberSamples → 2000, InterpolationOrderReg → 3, BsplineSpacing → 30,
BsplineDirections → {1, 1, 1}, AffineDirections → {1, 1, 1}, MethodReg → affine, OutputImage → True, TempDirectory → Default,
DeleteTempDirectory → True, PrintTempDirectory → True, OutputTransformation → False, UseGPU → False, Automatic, PCAComponents → 3
RegisterDataSplit[target, moving] is identical to RegisterData data however left and right side of the data are registered seperately.
Splitting the data is done using the function CutData and merged wit Stich data.
Output is the registered data.
moving2nd can have the same dimensions of moving or one dimension higher (e.g. 3D and 3D or 3D and 4D).
OptionsRegisterDataTransform =
Iterations → 250, Resolutions → 1, HistogramBins → 64, NumberSamples → 2000, InterpolationOrderReg → 3, BsplineSpacing → 30,
BsplineDirections → {1, 1, 1}, AffineDirections → {1, 1, 1}, MethodReg → affine, OutputImage → True, TempDirectory → Default,
DeleteTempDirectory → True, PrintTempDirectory → True, OutputTransformation → False, UseGPU → False, Automatic, PCAComponents → 3
RegisterDataTransformSplit[target, moving, {moving2nd, vox}] is idenditcal to RegisterDataTransform with the same functionality as RegisterDataSplit.
This means the data is split in two using the function CutData and merged wit Stich data.
RegisterDiffusionData[{dtidata, vox}] registers a diffusion dataset. dtidata should be 4D {slice, diff, x, y}. vox is the voxelsize of the data.
RegisterDiffusionData[{dtidata, dtimask, vox}] registers the data series using the given voxel size only using data within the mask.
RegisterDiffusionData[{dtidata ,vox}, {anatdata, voxa}] registers a diffusion dataset. The diffusion data is also registered to the anatdata.
RegisterDiffusionData[{dtidata, dtimask, vox}, {anatdata, voxa}] registers the data series using the given voxel size only using data within the mask.
RegisterDiffusionData[{dtidata,vox}, {anatdata, anatmask, voxa}] registers the data series using the given voxel size only using data within the mask.
RegisterDiffusionData[{dtidata, dtimask, vox}, {anatdata,
anatmask, voxa}] registers the data series using the given voxel size only using data within the mask.
Output is the registered dtidata and, if anatdata is given, the registered dtidata in anatomical space.
If OutputTransformation is True it also outputs the translation, rotation scale and skew of all images or volumes.
RegisterDiffusionDataSplit[dtidata, vox] is identical to Register diffusion data however left and right side of the data are registered seperately.
RegisterDiffusionDataSplit[{dtidata, vox}, {anatdata, voxa}] is
identical to Register diffusion data however left and right side of the data are registered seperately.
RegisterDiffusionDataSplit[{dtidata, dtimask, vox}, {anatdata, anatmask, voxa}] is identical to Register
diffusion data however left and right side of the data are registered seperately.
Splitting the data is done using the function CutData and merged wit Stich data.
Output is the registered data.
42 All-Functions.nb
OptionsRegisterDiffusionDataSplit := OptionsRegisterDiffusionData
TransformData[{data,vox}] deforms the data according to the last output of register data.
The directory should be the TempDirectory were the registration is stored. DeleteTempDirectory should be False.
Options
FindTransform is an option for TransformData and RegisterTransformData. It specifies where to find the transformfile.
PCAComponents is an option for RegisterData. It speciefies how many PCA components are used if method is set to "PCA"
All-Functions.nb 45
SplitMethod is an option for RegisterDataSplit and RegisterDataTransformSplit. values can be "mean", "moving", "target"
UseGPU is an option for RegisterData. The value is {bool, gpu} where bool is True or False, and gpu is the gpu ID which is an integer or Automatic.
46 All-Functions.nb
GeneralTools
Functions
ApplyCrop[data,crop] aplies the corpped region obtained form CropData to the data.
ApplyCrop[data,crop,{voxorig,voxnew}] aplies the corpped region obtained form CropData to the data.
Options[AutoCropData] = CropPadding → 5
CropData[data] creates a dialog window to crop the data (assumes voxsize (1,1,1)).
CropData[data,vox] creates a dialog window to crop the data.
All-Functions.nb 47
CutData[data] splits the data in two equal sets left and right.
output is the vecotrized data and a list contining the original data dimensions and a list with the data coordinates. {vec, {dim,pos}}.
output is the vecotrized data and a list contining the original data dimensions and a list with the data coordinates. {vec, {dim,pos}}.
DevideNoZero[a, b] devides a/b but when b=0 the result is 0. a can be a number or vector.
48 All-Functions.nb
ExpNoZero[val] return the Exp of the val which can be anny dimonsion array. if val=0 the output is 0.
FileSelect[action] creates a systemdialog wicht returs file/foldername action can be "FileOpen", "FileSave" or "Directory".
FileSelect[action, {type}] same but allows the definition of filetypes for "FileOpen" and "FileSave" e.g. "jpg" or "pdf".
FindCrop[data] finds the crop values of the data by removing all zeros surrounding the data.
OptionsFindCrop = CropPadding → 5
FindMaxDimensions[{data1, data2, ..}] finds the maximal dimensions of all datasets. Each dataset is 3D.
GridData[{data1,data2,...}, part] makes a grid of multiple datasets with part sets on each row
GridData3D[{data1,data2,...}, part] same as grid data, but only works on 4D data where the data is gridded in axial, coronal and sagital.
LogNoZero[val] return the log of the val which can be anny dimonsion array. if val=0 the output is 0.
MADNoZero[vec] return the MAD error of the vec which can be anny dimonsion array. if vec={0...} the output is 0. Zeros are ignored
QMRIToolsFuncPrint[] gives a list of all the QMRITools functions with their usage infomation.
QMRIToolsFunctions[] give list of all the QMRITools packages, functions and options.
QMRIToolsFunctions[p] print a table with length p of all the QMRITools functions and options.
QMRIToolsFunctions["toobox"] gives a list of all the functions and options in toolbox.
QMRIToolsFunctions["toobox", p] gives a table op length p of all the functions and options in toolbox. If toolbox is "All" it will list all toolboxes.
Options[RescaleData] = InterpolationOrder → 3
ReverseCrop[data,dim,crop] reverses the crop on the cropped data with crop values crop to the original size dim.
ReverseCrop[data,dim,crop,{voxorig,voxnew}] reverses the crop on the cropped data with crop values crop to the original size dim.
RMSNoZero[vec] return the RMS error of the vec which can be anny dimonsion array. if vec={0...} the output is 0. Zeros are ignored
SaveImage[image] exports graph to image, ImageSize, FileType and ImageResolution can be given as options.
SaveImage[image, "filename"] exports graph to image with "filname", ImageSize, FileType and ImageResolution can be given as options.
StichData[datal,datar] joins left and right part of the data generated by CutData.
52 All-Functions.nb
SumOfSquares[{data1, data2, .... datan}] calculates the sum of squares of the datasets.
Output is the SoS and the weights, or just the SoS.
TensMat[tensor] transforms tensor form vector format {xx,yy,zz,xy,xz,yz} to matrix format {{xx,xy,xz},{xy,yy,yz},{xz,yz,zz}}.
TensVec[tensor] transforms tensor form matrix format {{xx,xy,xz},{xy,yy,yz},{xz,yz,zz}} to vector format {xx,yy,zz,xy,xz,yz}.
TransData[data,dir] Rotates the dimesions of the data to left or rigthg. For example {z,x,y} to {x,y,z} dir is "l" or "r".
VectorToData[vec, {dim,pos}] converts the vectroized data, using Data2DToVector or Data3DToVector, back to its original Dimensoins
Options
CropInit is an option for CropData. By default the crop is not initialized bu can be with {{xmin,xmax},{ymin,ymax},{zmin,zmax}}.
All-Functions.nb 53
CropPadding is an option for AutoCropData or FindCrop. It specifies how much padding to use around the data.
AttributesFileType = {Protected}
ImageResolution is an option for Export, Rasterize, and related functions that specifies at what resolution bitmap images should be rendered.
AttributesImageResolution = {Protected}
ImageSize is an option that specifies the overall size of an image to display for an object.
AttributesImageSize = {Protected}
AttributesInterpolationOrder = {Protected}
OutputWeights is an option for SumOfSqares. If True it also output the SoS weights.
PadDirection is an option for PadToDimensions. It specifies the direction of padding, "Center", "Left" or "Right".
AttributesWindowTitle = {Protected}
GradientTools
Functions
Bmatrix[bvec,grad] creates bmatrix form grad and bvec in form {-bxx, -byy, -bzz, -bxy, -bxz, -byz ,1}.
Bmatrix[{bvec,grad}] creates bmatrix form grad and bvec in form {bxx, byy, bzz, bxy, bxz, byz}.
BmatrixCalc["folder", grads] calculates the true bmatrix from the exported sequence
parameters from the philips scanner that are stored in "folder" for each of the gradient directions grads.
OptionsBmatrixCalc = UseGrad → {1, 1, {1, 1}, 1, 1}, OutputType → Matrix, Method → Numerical,
1
StepSizeI → 0.05, UnitMulti → 1000
, PhaseEncoding → A, FlipAxes → {{1, 1, 1}, {1, 1, 1}}, SwitchAxes → {{1, 2, 3}, {1, 2, 3}}
BmatrixToggle[bmat, axes, flip], axes can be any order of {"x","y","z"}. flip should be {1,1,1},{1,1,-1},{1,-1,1} or {-1,1,1}.
CalculateMoments[{Gt, hw, te}, t] calculates the 0th to 3th order moments of the sequence created by GradSeq. Output is {{Gt, M0, M1, M2, M3}, vals}.
ConvertGrads[grad, bv] converts the gradients to txt format, which is needed for FinalGrads.
CorrectBmatrix[bmat, transformation] corrects the bmatrix bmat with the tranformation parameters from RegisterData or RegisterDiffusionData.
FindOrder[grad,bv] finds the optimal order of the gradient directions which minimizes the duty cycle.
The output is needed for FinalGrads.
grad is a list of gradient sets and bv is a list of b-values with the same number as the list of gradient sets.
All-Functions.nb 57
FullGrad is an option for Grad. Default is True. When true the gradient directions wil be loaded with the first gradient {0,0,0}.
OptionsGenerateGradients = Steps → 1000, Runs → 1, VisualOpt → False, GradType → Normal, ConditionCalc → False, FullSphere → False
GenerateGradientsGUI[] runs the GenerateGradients function in GUI with output for the philips system.
GetGradientScanOrder[grad, bval] determines the scanorder based on the txt file provided to the scanner as input.
GetGradientScanOrder[file, grad, bval] determines the scanorder based on the txt file provided to the scanner as input.
58 All-Functions.nb
GradBmatrix[Gt, hw, te, t] Calculates the true bmatrix from the sequence created by GradSeq.
GradSeq[pars, t, grad] Creates a sequence from the gradient pars imported by ImportGradObj.
ImportGradObj[folder] Imports the gradient par files exported from the philips scanner.
UniqueBvalPosition[bval] generates a list of all the unique bvalues and their positions.
UniqueBvalPosition[bval, num] generates a list of all the
unique bvalues and their positions that are present in the dataset equal or more than num times
Options
ConditionCalc is an option for GenerateGradients if set to true GenerateGradients will also give the condition number evolution of the system.
FlipGrad is an option for GradSeq. When FlipGrad is true the gr180 is fliped.
FullSphere is an option for GenerateGradients. If set True the gradients will be optimized on a full sphere rather than half a sphere.
GradType is what type of gradient set wil be produced in GenerateGradients "Normal" or "OverPlus".
Method is an option for various algorithm-intensive functions that specifies what internal methods they should use.
Attributes[Method] = {Protected}
OutputPlot is an option for GradBmatrix. It specifies if the plots of the gradients should also be exported.
PhaseEncoding is an options of GradSeq. Values can be "A", "P", "R" and "L".
Runs is an option for GenerateGradients. Set how often the minimalization function is run. The best solution of all runs is the output. Default value is 1.
StepSizeI is an option for GradBmatrix. Specifies the integration stepsize is Method -> "Numerical" is used.
All-Functions.nb 61
UnitMulti is an option for GradSeq. Defaul value is 10^-3. Defines the scaling of the gradient strength.
UseGrad is an option for GradSeq. The default value is {0, 1, {1, 0}, 1} where {grex, gr180, {grepi1, grepi2}, grdiff, grflow}.
VisualOpt is an option for GenerateGradients. Show the minimalization proces of eacht calculation step. Default is False.
ImportTools
Functions
BvalRead[file] imports the bvalue from a .dcm file. file must be a string.
ReadBrukerDiff[""] imports the bruker diffusion data selected by the input dialog.
ReadBrukerDiff["file"] imports the bruker diffusion data from "file", file must be location of 2dseq.
ReadBvalue[folder,nr] imports the gradient directions from the dicom header of the first nr of files in de given folder.
folder must be a string, nr must be a int. Uses BvalRead.
ReadDicomDiff[folder, part] imports all dicom files from the given folder and the corresponding diffusion parameters.
part is the number of diffusion images per slice including the unweighted images.
All-Functions.nb 63
ReadDicomDirDiff[file] reads the image data and relevant diffuison parameters from a dicom directory.
ReadGradients[folder, nr] imports the diffusion gradient directions from the dicom header of the first nr of files in de given folder.
ReadVoxSize[filename] imports the voxelsize from a .dcm file. filename must be a string.
Imports the pixel and slice spacing from the dicom header. Output is a list containg the voxels size {slice thickness, x, y}.
ShiftPar[B0file.dcm,DTIfile.dcm] imports the parameters from the dicom headeand and calculates the needed values to preform B0 field map correction.
Needs a B0 dicom file and a diffusion dicom file.
64 All-Functions.nb
Options
BmatrixOut is a option for ImportBrukerData if True the bmatrix is given, if false the gradients and bvec are given.
RotateGradient is an option for ReadDicomDirDiff. If False it will also output the gradient direction as stored in the dicom header.
IVIMTools
Functions
OptionsBayesianIVIMFit2 = ChainSteps → {20 000, 1000, 10}, UpdateStep → {0.5, 0.2, 0.5}, FixPseudoDiff → False, CorrectPar → True,
FixPseudoDiffSD → 0.5, OutputSamples → False, FitConstrains → ThetaConv[{{-7.6, 7.6}, {-10., -5.7}, {-7., 0.}}]
OptionsBayesianIVIMFit3 = ChainSteps → {20 000, 1000, 10}, UpdateStep → {0.5, 0.5, 0.1, 0.5, 0.5}, FixPseudoDiff → False, CorrectPar → True,
OutputSamples → False, FixPseudoDiffSD → 0.5, FitConstrains → ThetaConv[{{-7.6, 7.6}, {-7.6, 7.6}, {-10., -5.5}, {-6.5, -2.3}, {-5.2, 0.}}]
CorrectParMap[par, constraints, mask] removes the IVIM parameters outside the constraints within the mask.
FracCorrect[fraction, time] corrects the signal fraction calculated with the IVIM model for tissue relaxation and acquisition parameters.
After correction the signal fraction can be regarded as volume fraction.
FracCorrect[{fraction1, fraction2}, time] corrects the signal fraction1 and fraction2 from a 3 compartement IVIM model.
time is {{te, tr}, {t2t, t21}, {t1t, t11}} or {{te, tr}, {t2t, t21, t22}, {t1t, t11, t12}}
where t2t and t1t are "tissue" relaxation times and t11 t12, t21 and t22 the "fluid" relaxation times
HistogramPar[data, {constraints, Nbins}, style, color, range] plots histograms of IVIM solution.
HistogramPar[data, {constraints, Nbins, mu, conv}, components, color, range] plots histograms of IVIM solution.
Options[IVIMCalc] = Method → Automatic, Parallelize → True, MonitorIVIMCalc → True, IVIMFixed → False, IVIMConstrained → True,
IVIMTensFit → False, IVIMComponents → 2, IVIMConstrains → {{0.8, 1.2}, {0, 1}, {0.0005, 0.0035}, {0.001, 0.5}, {0.001, 0.5}}
IVIMCorrectData[data, {S0, f, pdc}, bval] removes the ivim signal from the data.
output is the function with b, S0, f1, f2, D, pD1, pD2 as parameters
IVIMResiduals[data, binp, pars] calculates the root mean square residuals of an IVIM fit ussing IVIMCalc, BayesianIVIMFit2 or BayesianIVIMFit3.
ThetaConv[{F1, Fc, pDc}] converts the parameters from Log space to normal space. Is used in BayesianIVIMFit2 and BayesianIVIMFit3.
ThetaConv[{F1, F2, Dc, pDc1}] converts the parameters from Log space to normal space. Is used in BayesianIVIMFit2 and BayesianIVIMFit3.
ThetaConv[{F1, F2, Dc, pDc1, pDc2}] converts the parameters from Log space to normal space. Is used in BayesianIVIMFit2 and BayesianIVIMFit3.
ThetaConvi[{f, dc, pdc}] converts the parameters from Normal space to Log space. Is used in BayesianIVIMFit2 and BayesianIVIMFit3.
ThetaConvi[{f1, f2, dc, pdc1}] converts the parameters from Normal space to Log space. Is used in BayesianIVIMFit2 and BayesianIVIMFit3.
ThetaConvi[{f1, f2, dc, pdc1, pdc2}] converts the parameters from Normal space to Log space. Is used in BayesianIVIMFit2 and BayesianIVIMFit3.
Options
ChainSteps is an option for BayesianIVIMFit2 and BayesianIVIMFit3. It determines how long the algorithm runs.
three values must be given {itterations, burn steps, sample density}.
CorrectPar is an option for BayesianIVIMFit2 and BayesianIVIMFit3. If True it removes the values outside the contraints using CorrectParMap
FilterMaps is an option for IVIMCorrectData. If True the IVIM parameter maps are filtered before signal correction
FilterSize is an option for IVIMCorrectData. If FilterMaps is True it gives the kernel size.
FilterType is an option for IVIMCorrectData. If FilterMaps is True it tells which filter to use. can be "Median" of "Gausian"
FitConstrains is an option for BayesianIVIMFit2 and BayesianIVIMFit3. Gives the contraints of the parameters.
The values are used for displaying the histograms and for the initialization if CorrectPar is True
FixPseudoDiff is an option for BayesianIVIMFit2 and BayesianIVIMFit3. If the pDc1 and pD2 were fixed in IVIMCalc this value should be True.
FixPseudoDiffSD is an option for BayesianIVIMFit2 and BayesianIVIMFit3. Gives the standard deviation of pDc1 and pD2 if FixPseudoDiff is True
IVIMComponents is an option for IVIMCalc. Default value is 2, the tissue and the blood component. can also be set to 3.
IVIMConstrained is an option for IVIMCalc. When set True the fit wil be constrained to the values given in IVIMConstrains.
IVIMConstrains is an option for IVIMCalc. Default values are: {{0.8, 1.2}, {0, 1}, {0.0005, 0.0035}, {0.005, 0.5},
{0.002, 0.015}}. Where {{S0 in percentage},{fractions},{tissue diffusion},{blood compartment Dp},{third compartment}}.
IVIMFixed is an option for IVIMCalc and the default value is False. When set True the pseudo diffusion wil be fixed to the parameter given as init.
When set to "One" only the fast component of a 3 compartment fit is fixed.
IVIMTensFit is an option for IVIMCalc. When set True the tissue diffusion component wil be calculated as a tensor.
Method is an option for various algorithm-intensive functions that specifies what internal methods they should use.
All-Functions.nb 71
Attributes[Method] = {Protected}
MonitorIVIMCalc is an option for IVIMCalc. When true the proceses of the calculation is shown.
OutputSamples is an option for BayesianIVIMFit2 and BayesianIVIMFit3. If set True the full marcov chain is given as an additionaln output.
ParallelizeParallel`Kernels`Private`args$___ := Parallel`Protected`doAutolaunchTrueQParallel`Static`$enableLaunchFeedback;
ParallelizeParallel`Kernels`Private`args$
JcouplingTools
Functions
PhaseAlign[spec] automatically phase aligns the spectrum by maximizing the Real part of the spectrum.
PlotSpectrum[ppm, spec] plots the spectrum, ppm and spec can be generated using SimReadout.
SequencePulseAcquire[din, H] performs a pulsaquire experiment of the spin system din given the hamiltonian H with a 90 Degree pulse.
SequencePulseAcquire[din, H, b1] performs a pulsaquire experiment of the spin system din given the hamiltonian H with a 90 Degree pulse and b1.
The output is a new spinsystem dout.
SequenceTSE[din ,H, {te, necho}, {ex, ref}] performs a multi echo spin echo experiment with echo time te with
necho echos of the spin system din given the hamiltonian H using ex Degree exitation and ref Degree refocus pulses.
SequenceTSE[din ,H, {te, necho}, {ex, ref}, b1_:1] performs a multi echo spin echo experiment with echo time te with necho
echos of the spin system din given the hamiltonian H using ex Degree exitation and ref Degree refocus pulses and b1.
The output is a new spinsystem dout.
SimAddPhase[din ,H ,phase] adds phase to the spin system din given the hamiltonian H.
din and H are generated by SimHamiltonian.
The output is a new spinsystem dout.
SimEvolve[din,H,t] evolves the spin system din given the hamiltonian H over a time t. din and H are generated by SimHamiltonian.
The output is a new spinsystem dout.
SimHamiltonian[sysi] simulates the hamiltionan for a given spin system. The spinsystem is generated by GetSpinSystem.
The output is the spin system and hamiltonian structure.
OptionsSimHamiltonian = FieldStrength → 3
OptionsSimReadout = ReadoutOutput → all, ReadoutPhase → 90, Linewidth → 5, LinewidthShape → L, ReadoutSamples → 2046, ReadoutBandwith → 2000
SimRotate[din, H ,angle] rotates the spin system din given the hamiltonian H over angele with phase 90 degrees.
SimRotate[din, H ,angle, phase] rotates the spin system din given the hamiltonian H over angele with phase.
din and H are generated by SimHamiltonian.
The output is a new spinsystem dout.
SimSpoil[din] spoils all the non zeroth order states of a spin system.
The output is a new spinsystem dout.
All-Functions.nb 75
SysTable[sys] shows the spinsystem as a table. The spinsytem is obtained form GetSpinSystem.
Options
FieldStrength is an option for SimHamiltonian. It defines the field strength for which the hamiltonian is calculated.
PlotRange is an option for graphics functions that specifies what range of coordinates to include in a plot.
ReadoutOutput is an option for SimReadout and SimSignal and values can be "all" and "each". When set to
"all" the total signal and signal is given, when set to "each" the signal or spectrum for each peak is given seperately.
ReadoutSamples is an option for SimReadout and defines the number of readout samples for the spectrum.
MaskingTools
Functions
HomoginizeData[data, mask] tries to homoginize the data within the mask by removing intensity gradients.
MaskData[data, mask] applies a mask to data. mask can be 2D or 3D, data can be 2D, 3D or 4D.
MergeSegmentations[masks, labels] generates an ITKsnap or slices3D compatible segmentation from individual masks and label numbers.
Output is a labled segmentation.
NormalizeData[data] normalizes the data to the mean signal of the data. For 4D data it normalizes to the first volume of the 4th dimension.
NormalizeData[data,{min,max}] normalizes the data between min and max.
78 All-Functions.nb
RemoveMaskOverlaps[mask] removes the overlaps between multiple masks. Mask is a 4D dataset with {z, masks, x, y}
SegmentMask[mask, n] devides a mask in n equal segments along the slice direction. n must be an integer.
SmoothSegmentation[masks] smooths segmentations and removes the overlaps between multiple segmentations.
All-Functions.nb 79
OptionsSmoothSegmentation = MaskFiltKernel → 2
SplitSegmentations[segmentation] splits a lable mask from ITKsnap or slicer3D in seperate masks and label numbers.
Output is masks and label numbers, {mask, labs}.
Options
GetMaskOutput is an option for GetMaskData. Defaul is "Slices" which gives the mask data per slices. Else the entire mask data is given as output.
MaskClosing is an option for Mask and SmoothMask. The size of the holes in the mask that will be closed
MaskComponents is an option for Mask and SmoothMask. Determinse the amount of largest clusters used as mask.
MaskFiltKernel is an option for Mask, SmoothMask and SmoothSegmentation. How mucht the contours are smoothed.
MaskSmoothing is an options for Mask, if set to True it smooths the mask, by closing holse and smoothing the contours.
NiftiTools
Functions
CompressNiiFiles[] promts for a folder. It then compresses all nii files to .nii.gz files in the selected folder.
CompressNiiFiles[folder] compresses all nii files to .nii.gz files in folder.
DcmToNii[] converts a dicom folder to nii, you will be prometed for the location of the folders.
DcmToNii[{"input","ouput"}] converts the "input" dicom folder to nii files which are place in the "output" folder.
For this function to work the dcm2niix.exe file should be present in the QMRITools aplication folder.
ExportNii[data, vox] exports the nii file and will promt for a file name.
ExportNii[data, vox, "file"] exports the nii file to the location "file".
ExtractNiiFiles[] promts for a folder. It then extracts all nii.gz files to .nii files in the selected folder.
ExtractNiiFiles[folder] extracts all nii.gz files to .nii files in folder.
ImportBmat[] will promt to select the *.txt file containing the bmatrix.
ImportBmat[*.txt] imports the given *.txt file containing the bmatrix.
ImportExploreDTItens["file"] imports the *.nii export for the tensor from explore DTI.
ImportNiiDiff[] will promt for the *.nii, *.bvec and *.bval file to import.
ImportNiiDiff[*.nii] will import the *.nii file and automatically also imports the *.bvec and *.bval is they have the same name.
ImportNiiDiff[*.nii,*.bvec,*.bval] will import the given files.
The output will be {data,grad,bvec,vox}.
All-Functions.nb 83
ImportNiiDix["file"] imports the dixon nii file which should contain all possible outputs given by the scanner and corrects them accordingly.
ImportNiiT1["file"] imports the T1 file which should contain the echos and the T1map calculated by the scanner and corrects them accordingly.
ImportNiiT2["file"] imports the T2 file which should contain the echos and the T2map calculated by the scanner and corrects them accordingly.
Options
CompressNii is an option for DcmToNii and ExportNii. If set True .nii.gz files will be created.
Method is an option for various algorithm-intensive functions that specifies what internal methods they should use.
Attributes[Method] = {Protected}
NiiDataType is an option of Export Nii. The number type of Nii file can be "Integer", "Real", "Complex", or "Automatic".
NiiMethod is an option for ImportNIi. Values can be "data", "dataTR", "header", "scaling", "headerMat", "rotation", "all".
NiiScaling is an option for ImportNii. It scales the nii values with scale slope and offset for quantitative data.
PhysiologyTools
Functions
ImportRespirect[] impors all the respirect log files from the folder selcted.
ImportRespirect["folder"] impors all the respirect log files from the "folder" selcted.
Options
PlottingTools
Functions
GetSliceData[data, offsets] gets the slices from the data defined by offsets which are obtained by GetSlicePosisions.
GetSliceData[data, offsets, vox] gets the slices from the data defined by offsets which are obtained by GetSlicePosisions in mm.
The offsets can also be provided manually which is {{AX,..},{COR,..},{SAG,..}}.
GetSlicePositions[data] finds the position of slices with the maximal signal in voxel index.
GetSlicePositions[data, vox] find the position of slices with the maximal signal in mm.
86 All-Functions.nb
GradientPlot[bvec, bval] plots the given bvec with position of the gradients scaled according to the bval.
MakeSliceImages[imgData] generates images from the imgData which is obtained form GetSliceData.
MakeSliceImages[imgData, vox] generates images from
the imgData which is obtained form GetSliceData, vox is used for the correct aspect ratio of the images.
MakeSliceImages[imgData, {labData, labels}] generates images from the imgData which is obtained form GetSliceData with
an overlay of the segmentations in labData, which can also be obtained using GetSliceData on the segmentations.
labels should be the label numbers used in the original segmentation (to allow correct scaling between slices).
MakeSliceImages[imgData, {labData, labels},vox] generates images from the
imgData which is obtained form GetSliceData with an overlay of the segmentations in labData, which can also
be obtained using GetSliceData on the segmentations, vox is used for the correct aspect ratio of the images.
PlotCorrection[w] plots deformation vectors w {w1,w2..} generated by Registration2D and Registration3D for multiple datasets or registration steps.
PlotData3D[data,vox] is a 3D dataviewer, data is the 3D dataset and voxsize the size of the voxels in mm (z,x,y).
PlotDefGrid[data, phasemap, shiftpar] plots the dataset on the background with on top the non deformed and the deformed grid, or arrows or lines.
PlotIVIM[vals, data, bvals] plots the results of the IVIM fits from IVIMCalc or BayesianIVIMFit2 or Baye.
Options[PlotIVIM] = Method → ,
PlotColor → {RGBColor[1, 0, 0], RGBColor[0, 1, 0], RGBColor[0, 0, 1], GrayLevel[0]}, NormalizeIVIM → Fit, PlotRange → Auto, ImageSize → 400
Options
ColorFunction is an option for graphics functions that specifies a function to apply to determine colors of elements.
AttributesColorFunction = {Protected}
ContourStyle is an option for contour plots that specifies the style in which contour lines or surfaces should be drawn.
Attributes[ContourStyle] = {Protected}
DropSlices is an option for GetSlicePositions and specifies how many slices from the beginning and and should be ignored.
ImageLegend is an option for MakeSliceImages, if set true a barlegend is added to the image.
ImageSize is an option that specifies the overall size of an image to display for an object.
AttributesImageSize = {Protected}
MakeCheckPlot is an option for GetSlicePositions and if set true gives a plot of the slices locations.
Method is an option for various algorithm-intensive functions that specifies what internal methods they should use.
Attributes[Method] = {Protected}
PeakNumber is an option of GetSlicePostitions and specifies how many slices per direction need to be found.
PlotColor is an option for GradientPlot can be any color or gradient color name.
PlotRange is an option for graphics functions that specifies what range of coordinates to include in a plot.
PositiveZ is an options for GradientPlot. If True all Gradients are displayed with a positive z direction.
90 All-Functions.nb
SphereColor ListSpherePlor. Default value is Automatic, If a color is given this color will be used for all spheres.
SphereSize is an option for GradientPlot and ListSpherePlor. Sets the size of the spheres thar represent the gradients.
ProcessingTools
Functions
OptionsDataTransformation = InterpolationOrder → 1
DatTot[{data1, data2, ..}, name, vox] calculates the parameter table conating the volume, mean, std and 95 CI for each of the diffusion parameters.
DatTotXLS[{data1, data2, ..}, name, vox] is the same as DatTot, but gives the parameters as strings for easy export to excel.
All-Functions.nb 91
ErrorPlot[data, xdata] plots a errorplot of the data where the first dim of the data is the xrange which matches the xdata list.
ErrorPlot[data, xdata, range] similar with a given y range.
FiberDensityMap[fiberPoins, dim, vox] generates a fiber density map for the fiberPoins which are imported
by LoadFiberTracts. The dimensions dim should be the dimensions of the tracked datasets van vox its volxel size.
FiberLengths[fpoints,flines] calculates the fiber lenght using the output from LoadFiberTacts.
FiberLengths[{fpoints,flines}] calculates the fiber lenght using the output from LoadFiberTacts.
FitData[data,range] converts the data into 100 bins within the +/- range around the mean. Function is used in ParameterFit.
92 All-Functions.nb
GetMaskMeans[dat, mask, name] calculates the mean, std, 5,50 and 95% CI form the given data for each of the given masks.
Mask can be genereated by SplitSegmentations. name is a string that is added to the header.
Hist[data, range] plots a probability density histogram of the data from xmin to xmax with a fitted (skew)normal distribution. Uses ParameterFit.
Hist[data, range, label] plots a probability density histogram
of the data from xmin to xmax with a fitted (skew)normal distribution and label as x-axis label.
Hist[{data1..,data2,..}, {range1,range2,..}] plots a probability density histogram of the data from xmin
to xmax with a fitted (skew)normal distribution. Uses ParameterFit.
Hist[{data1,data2,..}, {range1,range2,..}, {label1,label2,..}] plots a probability density histogram of the data
from xmin to xmax with a fitted (skew)normal distribution and label as x-axis label.
OptionsHist = ColorValue → {{GrayLevel[0], GrayLevel[1]}, RGBColor[1, 0, 0], RGBColor[0, 1, 0], RGBColor[0, 0, 1]},
Method → SkewNormal, PlotLabel → , AxesLabel → , ImageSize → 300
Hist2[pars, range] plots a probability density histogram of the data over range with two fitted (skew)normal distribution. Uses ParameterFit2.
Hist2[pars, range, label] plots a probability density histogram of the data over range with two fitted (skew)normal distribution. Uses ParameterFit2.
InvertDataset[data] inverts the data along the x y and z axes. In other words it is rotated aroud the origin such that (x,y,z)=(-x,-y,-z) and (0,0,0)=(0,0,0)
JoinSets[{dat1,dat2,...}, over] joins dat1, dat2, ... with over slices overlap.
JoinSets[{dat1,dat2,dat3...},{over1,over2,...}] joins
dat1 and dat2 with over1 slices overlap, Joins dat2 and dat3 with over2 slices overlap and so on.
JoinSets[{dat1,dat2,...},{{over,drop1,drop2},...}] joins dat1, dat2 with over slices overlap and drops drop1 slices for dat1 and drop2 from drop 2.
DOI: 10.1148/radiol.14140702.
OptionsJoinSets =
ReverseSets → True, ReverseData → True, NormalizeSets → True, MotionCorrectSets → False, PaddOverlap → 2, JoinSetSplit → True
MeanRange[Range] calculates the medain (50%) and standard deviation (14% and 86%) range and reports it as a string.
MeanStd[data] calculates the mean and standard deviation and reports it as a string.
NumberTableForm[data] makes a right aligned table of the numbers with 3 decimal percision.
NumberTableForm[data, n] makes a right aligned table of the numbers with n decimal percision.
94 All-Functions.nb
ParameterFit2[data] fits two skewNormal probaility density fucntions to the data. Assuming two compartments, one for fat and one for muscle.
SetupDataStructure[dcmFolder] makes nii folders and generates nii files for a directory of dmc data where the data is structured per subject.
SmartMask[input] crates a smart mask of input, which is either the tensor or the tensor parameters calculated using ParameterCalc.
SmartMask[input, mask] crates a smart mask of input and used the mask as a prior selection of the input.
SNRCalc[data,masksig,masknoise] calculates the Signal to noise ratio of the signal selected by masksig and the noise selected by masknoise.
All-Functions.nb 95
SNRMapCalc[{data1,data2}] calcualtes the signal to noise ratio from two identical images using MN[data1,data2] / (.5 SQRT[2] STDV[data2-data1]).
SNRMapCalc[{data1, .. dataN}] calcualtes the signal to noise ratio of the data using MN/sigma where the mean
signal MN is the average voxe value over all dynamics N and the sigma is the standard deviation over all dynamics N.
SplitSets[data, Nsets, Nover] splits the data in Nsets with Nover slices overlap.
Options
AxesLabel is an option for graphics functions that specifies labels for axes.
Attributes[AxesLabel] = {Protected}
FitFunction is an option for ParameterFit. Options are "Normal" or "SkewNormal". Indicates which function wil be fitted.
96 All-Functions.nb
FitOutput is an option for ParameterFit and ParameterFit2. Option can be "Parameters", "Function" or "BestFitParameters".
ImageSize is an option that specifies the overall size of an image to display for an object.
AttributesImageSize = {Protected}
AttributesInterpolationOrder = {Protected}
JoinSetSplit is an option ofr CorrectJoinSetMotion. If True RegisterDataTransformSplit is used else RegisterDataTransform is used.
MeanMethod is an option for GetMaskMeans. The option can be "NormalDist", "SkewNormalDist", or "Mean".
Method is an option for various algorithm-intensive functions that specifies what internal methods they should use.
Attributes[Method] = {Protected}
MotionCorrectSets is an option for JoinSets. True motion corrects the individual stacs before joining using CorrectJoinSetMotion.
NormalizeSets is an option for JoinSets. True normalizes the individual stacs before joining.
OutlierIncludeZero is an option for FindOutliers. If set to True all values that are zero are ignored and considered outliers.
OutlierIterations is an option for FindOutliers. Specifies how many iterations are used to find the outliers.
Each itteration the outliers are reevaluated on the data with the previously found outliers alread rejected.
OutlierOutput is an option for FindOutliers. If value is "Mask" it gives a list of 1 for data and 0 for outliers. Else the output is {data, outliers}.
OutlierRange is an option for FindOutliers. Specifies how many times the IQR is considred an oulier.
PaddOverlap is an option of CorrectJoinSetMotion and JoinSets. it allows for extra motion in the z direction.
PlotLabel is an option for graphics functions that specifies an overall label for a plot.
Attributes[PlotLabel] = {Protected}
ReverseData is an option for JoinSets. Reverses each individual datset given as input for the JoinSets function. True by default.
ReverseSets is an option for JoinSets. Reverses the order of the datsets, False by default.
Scaling is an option for Hist2. Scales the individual fits of the fat and muscle compartment.
SmartMaskOutput is an option for Smartmask. Can be set to "mask" to output only the mask or "full" to also output the probability mask.
SmartMethod is an option for SmartMask. This specifies how the mask is generated. Can be "Continuous" or "Catagorical"
Strictness is an option for SmartMask value between 0 and 1. Higer values removes more data.
TableAlignments is an option for TableForm and MatrixForm which specifies how entries in each dimension should be aligned.
AttributesTableAlignments = {Protected}
TableDepth is an option for TableForm and MatrixForm which specifies the maximum number of levels to be printed in tabular or matrix format.
Attributes[TableDepth] = {Protected}
TableDirections is an option for TableForm and MatrixForm which specifies whether successive dimensions should be arranged as rows or columns.
All-Functions.nb 99
AttributesTableDirections = {Protected}
TableHeadings is an option for TableForm and MatrixForm which gives the labels to be printed for entries in each dimension of a table or matrix.
AttributesTableHeadings = {Protected}
TableSpacing is an option for TableForm and MatrixForm which specifies how many spaces should be left between each successive row or column.
AttributesTableSpacing = {Protected}
RelaxometryTools
Functions
CalibrateEPGT2Fit[datan, times, angle] calculates the Fat T2 ralaxation that will be used in the EPGT2fit.
OptionsCalibrateEPGT2Fit = EPGRelaxPars → {{0, 100}, {20, 300}, {1400., 365.}}, EPGFitPoints → 50
CreateT2Dictionary[{T1m, T1f}, {Necho, echoSpace}, angle] Creates a EPG signal dictionary used for EPGT2fit.
Every dictionary that is defined is cached.
OptionsCreateT2Dictionary = DictB1Range → {0.5, 1.4, 0.01}, DictT2Range → {10., 70., 0.2}, DictT2fRange → {100., 200., 2.}
EPGSignal[{Necho, echoSpace}, {T1, T2}, {ex_angle,ref_angle}, B1] generates a EPG T2 curve with stimulated echos.
T1, T2 and echoSpace are in ms, angel is in degree, B1 is between 0 and 1.
EPGT2Fit[data, {Necho, detlaTE}, {exitation, refoucs}] fits the T2 based on Marty B et.al. Simultaneous
muscle water T2 and fat fraction mapping using transverse relaxometry with stimulated echo compensation.
Exitation and refocus are the RF pulse angles e.g. 90,180. They can also be a range of angeles over the slice profile as defined by GetSliceProfile.
OptionsEPGT2Fit =
DictB1Range → {0.5, 1.4, 0.01}, DictT2Range → {10., 60., 0.2}, DictT2fRange → {120., 170., 1.}, EPGRelaxPars → {1400., 365.},
EPGCalibrate → False, EPGFitPoints → 50, EPGMethod → dictionaryM, MonitorEPGFit → True, OutputCalibration → False, EPGSmoothB1 → True
NonLinearEPGFit[{vals, T2cons}, y] performs dictionary minimization of data y. vals = {{T1muscle, T1fat, T2fat}, {Necho, echoSpace, angle}}.
T1Fit[data, TR] fits the T1 value to the data using a nonlinear method.
T1rhoFit[data, EchoTimes] fits the T1rho value to the data using linear or nonlinear methdos.
T2Fit[data, EchoTimes] fits the T2 value to the data using linear or nonlinear methods.
Options
DictB1Range is an option for CreateT2Dictionary and EPGT2Fit. It specifies the range and step of the B1 values in the dictionary {min, max, step}.
DictT2Range is an option for CreateT2Dictionary and EPGT2Fit. is specifies the range and step of the T2 values in the dictionary {min, max, step} in ms.
EPGCalibrate is an option for EPGT2Fit. If set to True it does autmatic callibration of the T2 fat relaxation time.
EPGFitPoints is a option for CalibrateEPGT2Fit and EPGT2Fit. Number of points is 200 by default.
EPGRelaxPars is and option for EPGT2Fit. Needs to be {T1muscl, T1Fat, T2Fat} in ms, defaul is {1400,365,137}.
Method is an option for various algorithm-intensive functions that specifies what internal methods they should use.
Attributes[Method] = {Protected}
OutputCalibration is an option for EPGT2Fit and TriExponentialT2Fit. If true it outputs the calibartion values.
SimulationTools
Functions
AddNoise[data, noise] ads rician noise to the data with a given sigma or SNR value.
104 All-Functions.nb
CreateDiffData[sig, eig, bvec, gradients, dim] creates a DTI datasets of dimensions dim with sig as unweighted signal S0 and bvec and gradients.
eig can be {l1, l2, l3}, {{l1, l2, l3}, {e1, e2, e3}}, {{l1, l2, l3}, "Random"}, {{l1, l2, l3}, "RandomZ"} or {{l1, l2, l3}, "OrtRandom"}.
Uses Tensor internally.
GetPulseProfile[excitation, refocus] gives the pusl angle profiles for the exitation and refocussing pulses.
a pulse is defined as {"name", flipangle, {G_strnth, Dur, BW}}.
GetPulseProfile[{"name", flipangle, {G_strnth, Dur, BW}}] gives detaile slice profile information of one pulse.
GfactorSimulation[sensitivity, Wmat, {dir,sense}] calculates the gfactormaps for given sensitivity maps and noise corraltion W in one direction.
The sensefactors are a list of integers in a given direction: "LR", "FH", or "AP".
GfactorSimulation[sensitivity, Wmat, {dir1,sense1}, {dir2,sense2}]
calculates the gfactormaps for given sensitivity maps and noise corraltion W in two directions.
PlotSimulation[pars, xval, true, label, color] plots the pars (output form Parameters). Using
label as PlotLabel and xval as x axis Thics.tr are the true parameter values. color are the color used for the plot.
OptionsPlotSimulation = {PlotRange → {{0, 3}, {0, 3}, {0, 3}, {0, 3}, {0, 1}}}
PlotSimulationAngle[par, xdata, label, col] plots pars (output from Anlge Parameters).
Pulses[name] gives the pulse shape of some predefinec Philips pulse shapes.
Signal[par,TR,TE] calculates the MRI signal at a given TR and TE. Par is defineds as {pd, T1, T2}.
SimParameters[tens] caculates the diffusion parameters for tens. The output can be used in PlotSimulationHist and PlotSimulation.
All-Functions.nb 107
SimulateSliceEPG[exitation, refocus, {{T1, T2}, {Necho, echoSp}, b1}] gives a simulated slice profile and EPG singnal plot.
exitation and refocus are generated by GetPulseProfiel.
Tensor[{l1, l2, l3}] creates a diffuison tensor with vectors {{0,0,1},{0,1,0},{1,0,0}} and eigenvalues {l1, l2, l3}.
Tensor[{l1, l2, l3}, {e1, e2, e3}] creates a diffuison tensor with vectors {e1, e2, e3} and eigenvalues {l1, l2, l3}.
Tensor[{l1, l2, l3}, "Random"] creates a diffuison tensor with random orthogonal eigenvectors {e1, e2, e2} and eigenvalues {l1, l2, l3}.
Tensor[{l1, l2, l3}, "RandomZ"] creates a diffuison tensor with
random orthogonal eigenvectors {{1,0,0}, e2, e3} with random eigenvectors and eigenvalues {l1, l2, l3}.
Tensor[{l1, l2, l3}, "OrtRandom"] creates a diffuison tensor with random orthogonal eigenvectors {{1,0,0},{0,1,0},{0,0,1}} and eigenvalues {l1, l2, l3}.
Options
MagnetizationVector is an option for GetPulseProfile. It defines the start magnetization vector for the bloch simulation.
NoiseSize is an option for AddNoise. Values can be "Sigma", then the noise sigma is given or "SNR", then the SNR is given.
PlotRange is an option for graphics functions that specifies what range of coordinates to include in a plot.
Reject is an option for EigenvalCalc. It True then voxels with negative eigenvalues are rejected and set to 0.
ReportFits is an option for SimulateSliceEPG. If True it also reports the fit values
SliceRange is an option for GetPulseProfile. It specifies over which range the slice profile is generated (in mm). the total profile is 2xSliceRange.
SliceRangeSamples is an option for GetPulseProfile. defines how many samples are used to generate half a puls profile.
TensorTools
Functions
AngleCalc[data, vector] calculates the angel between the vector and the data. Data shoud be an array of dimensions {xxx,3}.
AngleMap[data] calculates the zennith and azimuth angles of a 3D dataset (z,x,y,3) containing vectors relative to the slice direction.
ColorFAPlot[tenor] create a color coded FA map from the tensor for l1, l2 and l3.
ConcatenateDiffusionData[{{data1, .., dataN}, {grad1, .., gradN}, {bval, .., bvalN}, {vox, .., voxN}}] concatenates the diffusion data sets.
ConcatenateDiffusionData[{data1, .., dataN}, {grad1, .., gradN}, {bval, .., bvalN}, {vox, .., voxN}] concatenates the diffusion data sets.
Correct[data, phase, shiftpar] corrects the dataset data using the phasemap and the shiftpar and interpolation order 1.
Correct[data, phase, shiftpar, int] corrects the dataset data using the phasemap and the shiftpar and interpolation order int.
110 All-Functions.nb
Deriv[disp, vox] calculates the derivative of the displacement along the three main axes. disp is the displacement field, vox is the voxel size.
Deriv[disp, vox, mask] calculates the derivative of the displacement along the three main axes. Sharp edges
between the background en disp are solved by the mask. mask is a mask delining the edge of the displacement field.
DriftCorrect[data, bval] dirft corrects the data using the signals of the lowest bvalue that has 6 or more unique volumes.
For the function to work optimal it is best to have these
volumes evenly spread througout thet data and for the first and last volume to have this low bvalue.
ParameterCalc[tensor] caculates the eigenvalues and MD and FA from the given tensor.
RemoveIsoImages[data, grad, bval] Romoves the ISO images from the philips scanner from the data. ISO images have g={0,0,0} and b>0.
SigmaCalc[DTI,grad,bvec] calculates the noise sigma based on the tensor residual, using a blur factor of 10.
SigmaCalc[DTI,tens,grad,bvec] calculates the noise sigma based on the tensor residual, using a blur factor of 10.
SigmaCalc[DTI,grad,bvec,blur] calculates the noise sigma based on the tensor residual, If blur is 1 ther is no blurring.
SigmaCalc[DTI,tens,grad,bvec,blur] calculates the noise sigma based on the tensor residual. If blur is 1 ther is no blurring.
SortDiffusionData[data, grad, bval] sorts the diffusion datasets grad and bval for magnitude of bvalue.
TensorCalc[data, gradients, bvalue] calculates the diffusion tensor for the given dataset. Allows for one unweighted image and one b value.
Gradient directions must be in the form {{x1,y1,z1}, ..., {xn,yn,zn}} without the unweighted gradient direction.
bvalue is a singe number indicating the b-value used.
TensorCalc[data, gradients, bvec] calculates the
diffusion tensor for the given dataset. allows for multiple unweighted images and multiple bvalues.
allows for differnt tensor fitting methods. gradient directions must be in the form {{x1,y1,z1}, ..., {xn,yn,zn}} with the unweighted
direction as {0,0,0}. bvec the bvector, with a bvalue defined for each gradient direction. b value for unweighted images is 0.
TensorCalc[data, bmatix] calculates the diffusion tensor for the given dataset. allows for multiple unweighted images and multiple bvalues.
bmat is the bmatrix which can be generated usiong Bmatrix.
Options[TensorCalc] =
MonitorCalc → True, Method → iWLLS, FullOutput → True, RobustFit → True, Parallelize → True, RobustFitParameters → {0.0001, 6}
TensorCorrect[tensor, phase, shift, vox] corrects the tensor based on B0 field map. Can perform both translation and rotation of tensor.
Options
Distribution is an option for AngleCalc. values can be "0-180", "0-90" and "-90-90".
FullOutput is an option for TensorCalc when using bvector. When True also the S0 is given as output.
MeanRes is an option for ResidualCalc. When True the root mean square of the residual is calculated.
Method is an option for various algorithm-intensive functions that specifies what internal methods they should use.
Attributes[Method] = {Protected}
MonitorCalc is an option for all Calc fucntions. When true the proceses of the calculation is shown.
ParallelizeParallel`Kernels`Private`args$___ := Parallel`Protected`doAutolaunchTrueQParallel`Static`$enableLaunchFeedback;
ParallelizeParallel`Kernels`Private`args$
Reject is an option for EigenvalCalc. It True then voxels with negative eigenvalues are rejected and set to 0.
RobustFit is an option for TensorCalc. If true outliers will be rejected in the fit, only works with WLLS.
If FullOutput is given the outlier map is given.
RobustFitParameters is an option for TensorCalc. gives the threshold for stopping the itterations and the kappa for the outlier marging, {tr,kappa}.
VisteTools
Functions
DatRead[file] imports data from file (dtitool *.dat format) as binary data using Real32 format.
DatWrite[file, data] exports data to *.dat file as binary data using Real32 format.
DTItoolExpInd[data, file] exports a 3D array data to the file filename DTItool format (*.dat) using DatWrite.
DTItoolExpInd[data, file ,folder] exports data to given file and folder.
DTItoolExpInd[data, file ,folder, add] exports data to given file and folder and adds -add to the filename.
ExportVol[filename, data, voxsize] exports a .vol and .raw file which can be loaded in DTItool 3.0.
ImportDTI[folder] imports xx.dat, yy.dat, zz.dat, xy.dat, xz.dat and yz.dat from the given folder.
ImportDTI[folder, add] imports xx-add.dat, yy-add.dat, zz-add.dat, xy-add.dat, xz-add.dat and yz-add.dat from the given folder.
ImportDTI[{file1, file2, ..}] imports the given *.dat files.
Options[ImportVol] = {}
Options
BinaryType is an option for ExportVol and must be "Integer16" for an integer array and "Real32" for a Double array.