Index
Contents
Name
mris_preproc
Synopsis
mris_preproc
Arguments
--out outfile
- --target subject --hemi hemi --meas surfmeas --area surfname
--s subj1 <--s subj2 ... --s subjN> --fsgd fsgdfile --f subjectlistfile
--is surfmeasfile <--is surfmeasfile> --srcfmt fmt : source format
--iv volmeasfile reg <--iv volmeasfile reg> --projfrac frac : projection fraction for vol2surf --sf sessfile : fsfast session file --df sessdirfile : fsfast session directory file --analysis analysis : fsfast analysis --contrast constrast : fsfast contrast --cvar : use fsfast contrast variance (cesvar) --offset : use fsfast mean offset (h-offset) --fwhm fwhm : smooth by fwhm mm on the target surface --fwhm-src fwhmsrc : smooth by fwhm mm on the source surface --niters niters : smooth by niters on the target surface --niters-src niterssrc : smooth by niters on the source surface --paired-diff --paired-diff-norm --paired-diff-norm1 --paired-diff-norm2 --cache-out cachefile --cache-in cachefile --cache-out-only tmpdir --mean : compute the mean of all inputs --reshape : reshape spatial dimensions
--surfreg SurfReg : default is sphere.reg --synth --tmpdir dir : use tmpdir. Implies --nocleanup. --nocleanup : do not delete tmpdir --cleanup : delete tmpdir (default) --help : short descriptive help --version : script version info --debug
Description
Script to prepare surface-based data for high-level analysis by resampling surface or volume source data to a common sujbect (usually an average subject) and then concatenating them into one file which can then be used by a number of programs (eg, mri_glmfit).
COMMAND-LINE ARGUMENTS
--out outfile
Save output here.
--target subject
Subject to use as the common-space. All the input data will be resampled to the surface of this subject.
--hemi hemi
Use hemi for source and target surfaces. hemi can be lh or rh.
--meas surfmeasure
Use subject/surf/hemi.surfmeasure as input. For use with --s, --fsgd, or --f. Implies --srcfmt curv.
--area surfname
Extract vertex area from subject/surf/hemi.surfname to use as input. For use with --s, --fsgd, or --f. surfname does not include hemi. Eg, white, pial.
--s subjN
Specify an input subject on the command-line. All subjects must be specified in this way on the command-line (ie, each with its own --s). For use with --meas.
--fsgd fsgdfile
Specify the list of input subjects from the fsgd file. The fsgd file can then be used with mri_glmfit (unless --paired-diff is specified). The subject list is obtained from the "Input" lines. See surfer.nmr.mgh.harvard.edu/docs/fsgdf.txt for more info. For use with --meas.
--f subjlistfile
List all subjects separated by white space in subjlistfile. This is just an alternative to using an fsgd file. For use with --meas.
--is surfmeasfile
Specify full path to input surface measure file. This is an alternative to using --meas. This still requires that a subject list be supplied.
--srcfmt fmt
Specify source format when using --is. This is mainly needed when the input format is not one recognized by mri_convert (eg, "curv" format that thickness files are in). --meas implies --srcfmt curv. Can also use "paint" or "w".
--iv volmeasfile
Specify full path to a volume file and its registration matrix file. The registration matrix file is of the type accepted/created by tkregister2. The volume is sampled to the surface, and the result is used as the input surface measure. This is an alternative to using --meas. This still requires that a subject list be supplied.
--projfrac projfrac
When sampling a volume onto the surface, sample a fraction of the thickness along the surface normal. projfrac is 0-1. Default is 0.
--fwhm fwhm
Smooth the data on the target surface by fwhm mm. As a workflow strategy, it might make more sense to run it without any smoothing, and then use mri_surf2surf to smooth the output. That way you can smooth to whatever levels you want without having to re-run mris_preproc.
--fwhm-src fwhm
Smooth the data on the source surface by fwhm mm. It is better to do it on the target surface.
--niters niters --niters-src niterssrc
Smooth target or source by niters or nitersrc nearest neighbor iterations. This is an alternative to specifying the smoothing level with FWHM.
--paired-diff
After concatenating all the inputs together, create a new output file by computing paired differences, ie, Input1-Input2, Input3-Input4, etc. There must be an even number of inputs.
--paired-diff-norm
Same as --paired-diff, but normalizes by average of time points, ie, (Input1-Input2)/((Input1-Input2)/2).
--paired-diff-norm1
Same as --paired-diff, but normalizes by time point 1, ie, (Input1-Input2)/Input1.
--paired-diff-norm2
Same as --paired-diff, but normalizes by time point 2, ie, (Input1-Input2)/Input2.
--cache-out cachefile --cache-in cachefile --cache-out-only tmpdir
Unless you are planning to do some type of semi-real-time processing, you can ignore caching. With --cache-out cachefile, mris_preproc will save the data for each subject, after resampling to the target and smoothing, in the subjects surf directory as hemi.cachefile. In a subsequent call to mris_preproc, you can specify --cache-in cachefile, and the precomputed data will be used. If you are going to smooth your data at some point, do it when caching out. If you want to cache without actually creating an output, then --cache-out-only. You must supply a tmpdir. The true tmpdir will be created under this. tmpdir itself will not be deleted. None of the paired diff options will affect caching.
- mris_preproc --target fsaverage --hemi lh --s subj1 --s subj2 \
- --meas thickness --fwhm 5 --cache-out thickness.avg7.sm5.mgh \ --cache-out-only tmp
- --cache-in thickness.avg7.sm5.mgh --out s12.thickness.avg7.sm5.mgh \
--mean
After concatenating all the inputs together (and possibly computing paired diffs), compute the mean of all inputs. This may be helpful as part of a lower-level analysis. Eg, if there are multiple measures for each subjects, these can be averaged together for each subject separately, then combined in a second call to mris_preproc.
--synth
Synthesize the input data with white gaussian noise. For volume source, the volume is synthesized prior to resampling to the surface. The synthesis is done prior to any smoothing. This is mainly good for testing and running simulations.
--surfreg SurfReg
Use hemi.SurfReg as the surface registration to the common space. Default is sphere.reg.
--reshape
Reshape spatial dimensions. Normally, the output volume-encoded surface file will have spatial dimension of nvertices-by-1-by-1 (ie, number of columns equals number of vertices, nrows=nslices=1). This will not work for ANALYZE and NIFTI formats because they cannot represent a dimension with more than 32k elements. This flag instructs mris_preproc to change the number of cols, rows, and slices so that no one dimension is greater than 32k. When ANALYZE and NIFTI formats are automatically detected, reshaping is turned on.
--tmpdir tmpdir
Use tmpdir. By default, creates a tmpdir in the output directory. Implies --nocleanup
--nocleanup
Do not delete temporary directory and files.
--cleanup
DO delete temporary directory and files. Done by default.
Examples
Example 1
- Resample abcXX-anat/surf/lh.thickness onto fsaverage:
mris_preproc --s abc01-anat --s abc02-anat --s abc03-anat --s abc04-anat \
- --target fsaverage --hemi lh --meas thickness --out abc-lh-thickness.mgh
Example 2
- Same as #1 but using an fsgd file (which would have the abcXXs as Inputs):
mris_preproc --fsgd abc.fsgd --target fsaverage --hemi lh --meas thickness \
- --out abc-lh-thickness.mgh
Example 3
- Same as #1 but smooths by 5mm fwhm:
mris_preproc --s abc01-anat --s abc02-anat --s abc03-anat --s abc04-anat \
- --target fsaverage --hemi lh --meas thickness \ --fwhm 5 --out abc-lh-thickness.sm5.mgh
Example 4
- Same as #1 but using full paths. Note there is no --meas, but
- --fsgd still needed to provide list of subjects, which must be in the same order as the --isp. Also note that --srcfmt curv is used:
mris_preproc --target fsaverage --hemi lh --out abc-lh-thickness.mgh \
- --fsgd abc.fsgd --srcfmt curv \ --isp abc01-anat/surf/lh.thickness \ --isp abc02-anat/surf/lh.thickness \ --isp abc03-anat/surf/lh.thickness \ --isp abc04-anat/surf/lh.thickness
Example 5
Same as #2 but computes paired differneces, ie, there will be two
- frames in the output instead of four. The first frame will be abc01-abc02, and the second frame will be abc03-abc04:
mris_preproc --fsgd abc.fsgd --target fsaverage --hemi lh --meas thickness \
- --out abc-lh-thickness-pdiff.mgh --paired-diff
Example 6
Sample volume data (no --meas):
mris_preproc --fsgd abc.fsgd --target fsaverage --hemi lh \
- --out abc-lh-vol.mgh \ --iv abc01-func/bold/main/nvr/ces.bhdr abc01-func/bold/register.dat \ --iv abc02-func/bold/main/nvr/ces.bhdr abc02-func/bold/register.dat \ --iv abc03-func/bold/main/nvr/ces.bhdr abc03-func/bold/register.dat \ --iv abc04-func/bold/main/nvr/ces.bhdr abc04-func/bold/register.dat
Bugs
None
See Also
Links
Methods Description
description description
References
Reporting Bugs
Report bugs to <analysis-bugs@nmr.mgh.harvard.edu>