analyzetype - return properties of analyze image datatype FORMAT: [anadata, anareadtype, anareadsize] = analyzetype(anatype) Input fields: anatype numeric datatype given in Analyze header Output fields: anadata 1x1 data field with correct type and zero content anareadtype type string for fread operations anareadsize number of bytes per pixel/voxel
These outputs are returned for the following input values:
{uint8(0), 'uint8⇒uint8', 1}
{int16(0), 'int16⇒int16', 2}
{int32(0), 'int32⇒int32', 4}
{single(0), 'single⇒single', 4}
{0, 'double⇒double', 8}
{int8(0), 'int8⇒int8', 1}
{uint16(0), 'uint16⇒uint16', 2}
{uint32(0), 'uint32⇒uint32', 4}
The function automatically handles incorrect endianness of the anatype value by deviding numbers greater than 255 by 256.