MTM Documentation
- Data-input-Diary (record)
- Data-input-Workspace (globals)
- Data-input-Load Data (loadIt)
- Data-input-Threshold (imgRng)
- Exploratory-Cine (cineIt)
- Exploratory-Mass Center (massCtr)
- Exploratory-Variance (std_dev)
- Exploratory-Physiologic (physioShow)
- Exploratory-Time SVD (timeSVD)
- Exploratory-Freq SVD (freqSVD)
- Popup to perform running linear regression detrending.
- Pre-processing-Denoise (physioCorr)
- Popup to calculate t-Test map.
- Confirmatory-Cross Corr (xcr)
- Confirmatory-Freq F-test (freqFtest)
- Confirmatory-Overlay (map_cmp)
Data-input-Diary (record)
doDiary
(diary control GUI)
The diary function is a standard matlab feature which saves the text of a MATLAB session. This gui provides a setPath browser to set the directory and filename for the diary log. The diary is enabled when run is pressed with the "Start" action selected. The diary is disabled when run is pressed with the "Stop" action selected.
doDiary GUI Tips
- Action --> Diary operation choice.
- browser --> Popup file browser.

Data-input-Workspace (globals)
globalMgr
(global GUI)
The globalMgr gui provides a setPath browser to set the directory and filename for use with the standard matlab save or load functions for global variables. The MTM GUI uses global variables to pass data between processing modules. Thus by saving the global variables, the workspace data of a session can later be loading during a subsequent session to continue with an analysis.
globalMgr GUI Tips
- Variables --> List the global variables on standard out.
- Action --> File operation choice.
- browser --> Popup file browser.

Data-input-Load Data (loadIt)
loadIt
(Load Data GUI)
The loadIt gui provides a setPath browser to set the
directory and filename for load of either functional 4D
data or anatomic 3D data. If the format is either fid
(Varian vnmr) or sdt (CMRR Stimulate), then upon setting
the path, the dimensions and data type are filled in
automatically. If the format is raw then the file is
assumed to be flat (i.e. no header) and the dimension and
type of the data need to be specified.
The head/tail trim parameters allow for removal of volumes
from the beginning or the ending of the data set during
the load. It is often necessary to remove the intial
pre-steady-state scans and/or the trailing phase reference
scan.
The volume acquisition frequency, volAcqFreq, is the
reciprocal of the slice TR (time repeat) multiplied by
the number of slices.
For fid files there is a multitaper outer-product filter
option which is enabled by selecting yes for dpssRecon
and by specifying both the Time-Bandwith product and the
number of dpss tapers to be used in the reconstruction
(i.e. Fourier transform).
The sdt format is actual a filepair with extensions of
'sdt' and 'spr' that hold the data and header respectively.
The data in the sdt is a flat file in the order of the
3 spatial dimensions first followed by the temporal
dimension. The spr is an ascii file that describes the
sdt with one colon separated attribute value pair per line.
There are three required attributes:
'numDim' - number of dimensions
'dim' - the numDim number of dimension values
'dataType' - the number format: {REAL, WORD, BYTE} which
corresponds to {float32, int16 or char} respectively.
an optional attribute is:
'endian' - {ieee-le, ieee-be} for little or big endian.
For example, an spr could contain...
numDim: 4
dim: 64 64 3 1000
dataType: REAL
endian: ieee-be
loadIt GUI Tips
- kind --> Data kind: 4D functional or 3D anatomic.
- format --> Data file format.
- browser --> Popup file browser.
- xDim --> Length of first spatial dimension.
- yDim --> Length of second spatial dimension.
- zDim --> Number of planes.
- tDim --> Number of volumes.
- dataType --> Matlab precision type. See FREAD
- endian --> Matlab machine format type. See FOPEN
- headTrim --> Number of volumes to remove from the beginning.
- tailTrim --> Number of volumes to remove from the end.
- volAcqFreq --> Volume acquisition frequency (aka drate).
- dpssRecon --> Boolean for use of dpss in image reconstruction.
- dpss_nw --> Time-Bandwith product for recon dpss. (0 < nw <= 1.5).
- dpss_k --> Number of dpss tapers for recon. (1 or 2)

Data-input-Threshold (imgRng)
ImgRng
image range GUI
The imgRng GUI provides several functions. A choice gui first allows the user to specify the data type, func or anat, and the plane index. When the run button is pressed, a popup window with the specified image is displayed. For the case of the 4D func data, a temporal average is used. Note that if the image looks like nothing but noise it may be that the endian was not specified correctly during the load. An initial guess at a display range (Min/Max) and the threshold are calculated. These values can be changed and the effect viewed after the Update button is pressed. There are three menu choices to view the threshold result; None, Less-than, or greater-than-or-equal. Note that these choices are for display purposes only. The threshold value is used to generate a processing mask with a greater-than-or-equal threshold logic regardless of the display choice. On the right hand side of the imgRng popup window are P-value parameters. Given the desired Global P value, the minimum activation cluster size and the number of tapers for the F-test, the adjusted P value is calculated along with the corresponding cross correlation level and F-Test significance level. These values are calculated using both the Polyomino and Bonferroni methods.
imgRngChoice GUI Tips
- imgKind --> Data kind: 4D functional or 3D anatomic.
- plane --> Index of image planes.

Exploratory-Cine (cineIt)
cineIt
Generate and Show a movie of data.
The cineIt GUI is used to specify parameters to generate a movie of the functional data. Use of this animation is an effective way to visually detect subject motion. Pressing the run button invokes the generation of the movie which results in a popup window movie viewer.
cineIt GUI Tips
- first --> Temporal index to the first volume.
- step --> Number of temporal indices to skip between movie frames.
- last --> Temporal index to the last volume.
- rep --> Planar dimension replication factor.
- sliceNum --> Index of slice to process.

Exploratory-Mass Center (massCtr)
massCntr
Calculate and display the center of mass.
The massCntr GUI is used to calculate and display the timecourse and spectrum of the center of mass. This is also an effect way to detect subject motion.
massCntr GUI Tips
- X_MC_TC --> Plot color for X dimension mass center time course
- X_MC_Spec --> Plot color for X dimension mass center spectrum
- Y_MC_TC --> Plot color for Y dimension mass center time course
- Y_MC_Spec --> Plot color for Y dimension mass center spectrum
- Z_MC_TC --> Plot color for Z dimension mass center time course
- Z_MC_Spec --> Plot color for Z dimension mass center spectrum

Exploratory-Variance (std_dev)
showVar
Calculate and display the variance over time.
The showVar GUI is used to calculate and display the variance of the time courses of the functional data. The Calculate button must be pressed to invoke processing. Pressing the RUN button will popup a display of the variance map overlayed onto the specified background. If the OvlThres and MaxOvlRng are not specified (i.e. set to 0) then values are automatically determined. If the plot timeCourse option is selected, then clicking on the displayed variance map will result in the associated timecourse being plotted.
showVar GUI Tips
- Variance --> Calculate the time variance of the functional data.
- Background --> Type of image for background.
- sliceNum --> Slice number to display.
- OvlThres --> Threshold value for overlay.
- MaxOvlRng --> Maximun display value for scaling overlay.
- MinCluster --> Minimum cluster size for overlay display.

Exploratory-Physiologic (physioShow)
physioShow
Popup to load and display physiologic waveforms
The physioShow GUI is used to load and display the physiologic timecourses and average functional timecourse. First the Load button must be pressed to popup the physioLoad GUI for loading of the physiologic data. The PlotType menu allows the user to specify plotting of cardio, respir, average functional time series or all three of them. When spectrum check box is selected, the corresponding spectrum is also plotted. Note that the spectrum of the time series average is the "average of the time series' spectrums" and NOT the "spectrum of the average time series". For reference, a vertical line is plotted at the frequency specified in the field lineFreq.
physioShow GUI Tips
- Data --> Popup physioLoad window.
- PlotType --> Type of data to plot.
- lineFreq --> Frequency at which to draw a line in the spectrum.

Exploratory-Time SVD (timeSVD)
showTimeSVD
Popup to perform a Time-Space SVD
The showTimeSVD GUI is used to view the spatial magnitude and time series of the leading modes from an SVD. First the process button must be pressed to popup the timeSVD window where the SVD can be invoked. After the SVD has been calculated, a particular mode can be viewed by specifing the index in the modeNum field. For reference, a vertical line is plotted at the frequency specified in the field lineFreq. When the RUN button is pressed, a figure is displayed with an image of the spatial magnitude along with a plot of both the timeseries and its spectrum for the specified mode.
showTimeSVD GUI Tips
- doTimeSVD --> Popup timeSVD processing window.
- modeNum --> Index of the mode to display.
- lineFreq --> Frequecny at which to draw a line in the spectrum.
timeSVD GUI Tips
- sliceNum --> Index of slice to process.
- nkept --> Number of modes to keep.

Exploratory-Freq SVD (freqSVD)
freqSVD
Popup to perform a Freq-Space SVD
The showFreqSVD is used to view the spatial magnitude and phase images of the mode at the specified frequency along with the mode time course. The coherence spectrum is also ploted with a vertical line is plotted at the frequency specified. First the process button must be pressed to popup the freqSVD window where the SVD can be invoked.
showFreqSVD GUI Tips
- doFreqSVD --> Popup freqSVD processing window.
- sliceNum --> Slice number to display.
- dispFreq --> Frequency for coherence image to display.
- cohRng --> Method for specifing coherence display range.
- minCohVal --> Minimum coherence display value.
- maxCohVal --> Maximum coherence display value.
The freqSVD GUI allows for the user to specify the multitaper parameters and the range of frequencies to compute the SVD on. When the RUN button is pressed, the SVD calculation is invoked.
freqSVD GUI Tips
- nw --> Slepian Time-Bandwidth product.
- k --> Number of Slepian tapers (usu. 2nw-1)
- freqMin --> Minimum frequency of fsvd calculation.
- df --> Frequency step for fsvd calculation.
- freqMax --> Maximum frequency of fsvd calculation.

Popup to perform running linear regression detrending.
runlineDetrend
Pre-processing-Detrend (runline)
The runlineDetrend GUI allows for the user to specify the runline detrending parameters. The detrending is done on a piecewise linear basis. The runlen parameter specifies the length of the window of the time series used to calculate the linear trend. Successive trends are calculated by running the window along the time series in steps of the size given by the parameter stepSize. When the RUN button is pressed, the detrending is invoked. Appropriate detrend parameters are very data dependent so the user can test the detrending by pressing display button to popup a detrend test window. The detrendTest shows an image that when clicked by the mouse plots the underlying time series in black with the calculated trend overlayed in red.
runlineDetrend GUI Tips
- runLen --> Length of running window.
- stepSize --> Stepsize of running window.
- plane --> Image plane to display.
- Test --> Popup detrend test window.

Pre-processing-Denoise (physioCorr)
Popup to perform physiologic noise removal.

Popup to calculate t-Test map.
T Test
Confirmatory-T-test (tTest)
The showTTest GUI allows the user display the results (i.e. Tvalue or Confidence (1.0 - Pvalue)) of a t-test as an overlay map on top of the corresponding slice of either the functional or anatomic data. The overlay map is color coded along a scale from the threshold value to the MaxOvlRng. Those pixels who belong to a cluster with a size smaller than the MinCluster are not shown in the map. If the PercentChg Plot option is selected, then when the image is clcked by the mouse the underlying time series is plotted with optionally the periods bars overlayed. First the process button must be pressed to popup the ttest window where the ttest can be invoked.
showTTest GUI Tips
- tTest --> Popup the T-test processing window.
- Background --> Type of image for background.
- sliceNum --> Slice number to display.
- Overlay --> Type of image for overlay.
- OvlThres --> Threshold value for overlay.
- MaxOvlRng --> Maximun display value for scaling overlay.
- MinCluster --> Minimum cluster size for overlay display.
The ttest GUI allows the user to specify the t-test parameters and invoke the calculation by pressing the RUN button.
ttest GUI Tips
- numStim --> Number of stimulation/task periods.
- isi --> Inter-stimulus interval in volAcq units.
- stimLen --> Stimulation length in volAcq units.
- tau --> Delay until the first stimulation period in volAcq units.

Confirmatory-Cross Corr (xcr)
XCR
Popup to calculate Cross correlation map.
The showXcr GUI allows the user display the results (i.e. Value of or lag at the maximum correlation) of a cross correlation as an overlay map on top of the corresponding slice of either the functional or anatomic data. The overlay map is color coded along a scale from the MinOvlRng and MaxOvlRng for those pixels with a correlation value that is no less than the xcr_thres value and who belong to a cluster with a size no smaller than the MinCluster. If the timeCourse plot option is selected, then when the image is clcked by the mouse the underlying time series is plotted with optionally the correlation sequence and/or the reference vector. First the process button must be pressed to popup the xcr window where the xcr can be invoked.
showXcr GUI Tips
- XCR --> Popup the Cross-Correlation processing window.
- Background --> Type of image for background.
- sliceNum --> Slice number to display.
- Overlay --> Type of image for overlay.
- xcr_thres --> XCR threshold value for overlay mask.
- MinOvlRng --> Minimun display value for scaling overlay.
- MaxOvlRng --> Maximun display value for scaling overlay.
- MinCluster --> Minimum cluster size for overlay display.
The xcr GUI allows the user to specify the xcr parameters and invoke the calculation by pressing the RUN button.
xcr GUI Tips
- numStim --> Number of stimulation/task periods.
- isi --> Inter-stimulus interval in volAcq units.
- stimLen --> Stimulation length in volAcq units.
- tau --> Delay until the first stimulation period in volAcq units.
- Plot --> Plot the xcr boxcar reference vector.
- lag --> Number of lags to compute in volAcq units.

Confirmatory-Freq F-test (freqFtest)
MultiTaper F-test
Popup to calculate a Frequency F-test map.
The showMtft GUI allows the user display the results (i.e. f-Value, magnitude or phase) of a multitaper f-test for a particular frequency as an overlay map on top of the corresponding slice of either the functional or anatomic data. The overlay map is color coded along a scale from the threshold value to the MaxOvlRng. Those pixels who belong to a cluster with a size smaller than the MinCluster are not shown in the map. If the PercentChg Plot option is selected, then when the image is clcked by the mouse the underlying time series is plotted along with optionally the Fstatistic and power spectrums and/or the average F-statistic over all pixels.
showMtft GUI Tips
- do_mtft --> Popup the multi-taper F-test processing window.
- Background --> Type of image for background.
- sliceNum --> Slice number to display.
- Overlay --> Type of image for overlay.
- F_freq --> F-test Frequency to display.
- F_thres --> Threshold value for F-stat mask.
- MinOvlRng --> Minimun display value for scaling overlay.
- MaxOvlRng --> Maximun display value for scaling overlay.
- MinCluster --> Minimum cluster size for overlay display.
The mtft GUI allows the user to specify the mtft parameters and invoke the calculation by pressing the RUN button. An appropriate npad can be automatically calculated based on the isi by pressing the auto_npad calculate button.
mtft GUI Tips
- nw --> Slepian Time-Bandwidth product.
- k --> Number of Slepian tapers (usu. 2nw-1)
- freqMin --> Minimum frequency of f-test calculation.
- freqMax --> Maximum frequency of f-test calculation.
- npad --> DFT zero paddding.
- padFactor --> Multiplication factor to determine npad.
- isi --> Inter-stimulus interval in volAcq units.
- auto_npad --> Calculate adequate npad.

Confirmatory-Overlay (map_cmp)
Map Compare
Popup to compare map overlays.
The showCmp GUI allows the user display a comparison between the resulting maps from any pair of activation maps previously calculated. When the user presses the RUN button, a comparison map is calculated and displayed. The comparison map is color coded to indicate at each pixel whether there was activation in the first map, the second map or in both maps. If the timeCourse Plot option is selected, then when the image is clcked by the mouse the underlying time series is plotted.
showCmp GUI Tips
- Background --> Type of image for background.
- sliceNum --> Slice number to display.
- Map_A --> Map A selection.
- Map_B --> Map B selection.

Return to MTM
Staff Login