Main Content

dicomlookup

Find attribute in DICOM data dictionary

Description

example

nameOut= dicomlookup(group,element)看着当前并建置data dictionary for the attribute with the specified group taggroupand element tagelement.dicomlookupreturns the name of the attribute.

[groupOut,elementOut] = dicomlookup(name)看着当前并建置data dictionary for the attribute specified bynameand returns the group and element tags associated with the attribute.

Examples

collapse all

Find the names of DICOM attributes using their tags.

name1 = dicomlookup(“7FE0","0010")
name1 = 'PixelData'
name2 = dicomlookup(40,4)
name2 = 'PhotometricInterpretation'

Look up the group and element of a DICOM attribute by the attribute name.

[group,element] = dicomlookup("TransferSyntaxUID")
group = 2
element = 16

Read the metadata of a DICOM file. Access the value of a metadata attribute in the file by specifying its group and element tag. This returns the same value even if the data dictionary changes.

metadata = dicominfo("CT-MONO2-16-ankle.dcm"); metadata.(dicomlookup("0028","0004"))
ans = 'MONOCHROME2'

Input Arguments

collapse all

DICOM group tag, specified as a positive integer decimal number or a character vector or string scalar that contains a hexadecimal value.elementandgroupmust use the same type of value:

  • Ifgroupis a positive integer decimal number, thenelement也必须是一个正整数十进制数。

  • Ifgroupis a character vector or string scalar that contains a hexadecimal value, thenelementmust be either a character vector or a string scalar that contains a hexadecimal value.

Example:40

Example:'7FE0'or“7FE0"

Data Types:single|double|int8|int16|int32|int64|uint8|uint16|uint32|uint64|char|string

DICOM element tag, specified as a positive integer decimal number or a character vector or string scalar that contains a hexadecimal value.elementandgroupmust use the same type of value:

  • Ifgroupis a positive integer decimal number, thenelement也必须是一个正整数十进制数。

  • Ifgroupis a character vector or string scalar that contains a hexadecimal value, thenelementmust be either a character vector or a string scalar that contains a hexadecimal value.

Example:4

Example:'0010'or"0010"

Data Types:single|double|int8|int16|int32|int64|uint8|uint16|uint32|uint64|char|string

DICOM attribute name, specified as a character vector or string scalar.

Example:'PhotometricInterpretation'or"PhotometricInterpretation"

Data Types:char|string

Output Arguments

collapse all

Returned DICOM group tag, returned as a positive integer decimal number.

Data Types:double

Returned DICOM element tag, returned as a positive integer decimal number.

Data Types:double

Returned DICOM attribute name, returned as a character vector.

Data Types:char

Version History

Introduced in R2006b