dicom.tag.parser {espadon} | R Documentation |
DICOM TAG parser
Description
the dicom.tag.parser
function decodes the content between
two DICOM raw data addresses.
Usage
dicom.tag.parser(start, stop, VR, endian, dicom.raw.data, try.parse = FALSE)
Arguments
start |
Positive integer. Index of the first raw data to parse in the
|
stop |
Positive integer. Index of the last raw data to parse in the
|
VR |
Character string, representing the value representation of DICOM data. See DICOM standard. |
endian |
Character string, equal to "little" or "big". |
dicom.raw.data |
Raw vector, representing the binary extraction of the DICOM file. |
try.parse |
Boolean. If |
Value
Returns the dicom.raw.data
content between the addresses
start
and stop
. Depending on the representation of the value
(VR
), it can be a character string or a numerical vector.
Examples
# creation of the toy.dicom.raw () addresses dataframe:
df <- dicom.browser (toy.dicom.raw ())
# search for modality of toy.dicom.raw ()
idx <- grep ("^[(]0008,0060[)]$", df$tag)
modality <- dicom.tag.parser (df$start[idx], df$stop[idx], df$VR[idx],
df$endian[idx], toy.dicom.raw ())
modality
[Package espadon version 1.7.2 Index]