dicm2nii.m converts dicom files in a zip file or in a folder (including sub-folders) into nifti files. It can also convert Philips PAR/REC files and AFNI HEAD/BRIK files into nifti files.
1. Support nii(.gz) and hdr/img(.gz) output.
2. Create bval and bvec files if there is DTI series.
3. Store B0 unwarping parameters in nifti header, such as delta TE for fieldmap, and effective echo spacing, TE and phase encoding direction for EPI data.
4. Store slice timing related information in nifti header (except for Philips).
5. Unique and descriptive result file names.
6. Several useful dicom functions, like reading header or image, sorting dicom files, renaming dicom files, are included.
7. Included nii_tool can read/write almost any kinds of NIfTI files, including different NIfTI versions and RGB NIfTI for different software.
'doc dicm2nii' or 'help dicm2nii' for details and usage.