Main Content

matlab.io.hdfeos.sw.readAttr

Namespace: matlab.io.hdfeos.sw

Read swath attribute

Syntax

data = readAttr(swathID,attrname)

Description

data = readAttr(swathID,attrname) reads a swath attribute.

This function corresponds to the SWreadAttr function in the HDF-EOS library C API.

Examples

import matlab.io.hdfeos.*
swfid = sw.open('swath.hdf');
swathID = sw.attach(swfid,'Example Swath');
value = sw.readAttr(swathID,'creation_date');
sw.detach(swathID);
sw.close(swfid);

See Also