Main Content

matlab.io.hdfeos.gd.dimInfo

Namespace: matlab.io.hdfeos.gd

Length of dimension

Syntax

dimlen = diminfo(gridID,dimname)

Description

dimlen = diminfo(gridID,dimname) retrieves the length of the specified user-defined dimension.

Please note that the two extents used to create the grid are not considered user-defined dimensions. To retrieve the length of XDim and YDim, use gd.gridInfo. This function corresponds to the GDdiminfo function in the HDF-EOS library C API.

Examples

Inquire about a 'Bands' dimension.

import matlab.io.hdfeos.*
gfid = gd.open('grid.hdf');
gridID = gd.attach(gfid,'PolarGrid');
dimlen = gd.dimInfo(gridID,'Height');
gd.detach(gridID);
gd.close(gfid);