Learn R Programming

oro.dicom (version 0.2.4)

Create: Create Arrays from DICOM Headers/Images

Description

A DICOM list structure is used to produce a multi-dimensional array representing a single acquisition of medical imaging data.

Usage

create3D(dcm, mode = "double", transpose = TRUE, pixelData = TRUE, ...)

Arguments

dcm
is the DICOM list structure (if pixelData = TRUE) or the DICOM header information (if pixelData = FALSE).
mode
is a valid character string for storage.mode.
transpose
is necessary to switch the definition of rows and columns from DICOM to R.
pixelData
is a logical variable (default = TRUE) that is associated with the DICOM image data being pre-loaded.
...
...

Value

  • Multi-dimensional array of medical imaging data.

References

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

See Also

array, dicomInfo, storage.mode

Examples

Run this code
## pixelData = TRUE
## The DICOM image data are read from dicomSeparate()
dcmList <- dicomSeparate(system.file("hk-40", package="oro.dicom"))
dcmImage <- create3D(dcmList, mode="integer")
graphics::image(dcmImage[,,1], col=grey(0:64/64), axes=FALSE,
                xlab="", ylab="")

## pixelData = FALSE
## The DICOM image data are read from create3D()
## This may save on memory for large batches of DICOM data
dcmList <- dicomSeparate(system.file("hk-40", package="oro.dicom"),
                         pixelData=FALSE)
dcmImage <- create3D(dcmList, mode="integer", pixelData=FALSE)
graphics::image(dcmImage[,,1], col=grey(0:64/64), axes=FALSE,
                xlab="", ylab="")

Run the code above in your browser using DataLab