dicom2nifti: Convert DICOM Header to NIfTI

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/dicom2nifti.R

Description

A subset of header information from DICOM is placed into NIfTI-1 format.

Usage

1
2
3
dicom2nifti(dcm, datatype = 4, units = c("mm","sec"), rescale = FALSE,
            reslice = TRUE, qform = TRUE, sform = TRUE, DIM = 3,
            descrip = "SeriesDescription", aux.file = NULL, ...)

Arguments

dcm

DICOM object containing both header and image information.

datatype

is an integer that denotes the type of data contained in each voxel. See convert.datatype or the NIfTI documentation for more details.

units

Spatial and temporal units for xyzt

rescale

Should slope and intercept parameters be extracted from the DICOM headers and saved?

reslice

Logical variable (default = TRUE) indicating if the data volume should be resliced.

qform

Logical variable (default = TRUE) indicating if the 3D image orientation should be used.

sform

Logical variable (default = TRUE) indicating if the 3D image orientation should be used.

DIM

The dimension of the array to be used (default = 3D).

descrip

DICOM header field(s) to be included in the descrip slot for the nifti class object.

aux.file

Character string to be included in the aux_file slot for the nifti class object.

...

Arguments to be passed to nifti

Details

See the references.

Value

An object of class nifti.

Author(s)

Brandon Whitcher bjw34032@users.sourceforge.net

References

Digital Imaging and Communications in Medicine (DICOM)
http://medical.nema.org

NIfTI-1
http://nifti.nimh.nih.gov/nifti-1

See Also

convert.datatype, dicom2analyze, nifti

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Not run: 
dcmList <- dicomSeparate(system.file("hk-40", package="oro.dicom"))
require("oro.nifti")
dcmNifti <- dicom2nifti(dcmList, datatype=4, mode="integer")
qform(dcmNifti)
sform(dcmNifti)
image(dcmNifti)
orthographic(dcmNifti)

## End(Not run)

oro.dicom documentation built on May 2, 2019, 6:07 p.m.