processing-scripts
processing-scripts > RE: questions about input files
Mar 22, 2012 02:03 PM | Maarten Mennes
RE: questions about input files
Hi Xinyuan,
1. You are correct, there is no to3d in the commands. That is becase the images required by the script are 3- or 4-D nifti images, instead of the 2D dicoms you would combine into a 3D image with to3d. So yes, if you have 2D dicoms you want to convert them into 3d nifti images first, .nii.gz is probably preferred as that will save you some diskspace.
2. Yes, that is the function of to3d. It combines 2D datasets into 3d data or even 4d if you feed it functional data. Alternatively you can alos use dcm2nii from mricron which might be more straightforward to use in that it reads whatever it needs from the headers, whereas you need to provide to3d with all the relevant parameters.
3. The $1, $2 etc. are command line arguments that you can give to a script. e.g., sample.sh 10 /home/me --> here the script, sample.sh will use 10 as its first input, e.g., value=$1 (thus value=10) and dir=$2 (thus dir=/home/me)
Best,
Maarten
1. You are correct, there is no to3d in the commands. That is becase the images required by the script are 3- or 4-D nifti images, instead of the 2D dicoms you would combine into a 3D image with to3d. So yes, if you have 2D dicoms you want to convert them into 3d nifti images first, .nii.gz is probably preferred as that will save you some diskspace.
2. Yes, that is the function of to3d. It combines 2D datasets into 3d data or even 4d if you feed it functional data. Alternatively you can alos use dcm2nii from mricron which might be more straightforward to use in that it reads whatever it needs from the headers, whereas you need to provide to3d with all the relevant parameters.
3. The $1, $2 etc. are command line arguments that you can give to a script. e.g., sample.sh 10 /home/me --> here the script, sample.sh will use 10 as its first input, e.g., value=$1 (thus value=10) and dir=$2 (thus dir=/home/me)
Best,
Maarten
Threaded View
| Title | Author | Date |
|---|---|---|
| Xinyuan Miao | Mar 22, 2012 | |
| Maarten Mennes | Mar 22, 2012 | |
