[Back to Interface] [Prev] [Next]

SDselect/sfselect

int32 SDselect(int32 sd_id, int32 sds_index)

sd_id IN:

SD interface identifier returned by SDstart

sds_index IN:

Index of the data set

Purpose

Obtains the data set identifier (sds_id) of a data set.

Return value

Returns the data set identifier (sds_id) if successful and FAIL (or -1) otherwise.

Description

SDselect obtains the data set identifier (sds_id) of the data set specified by its index, sds_index.

The integration with netCDF has required that a dimension (or coordinate variable) is stored as a data set in the file. Therefore, the value of sds_index may correspond to the coordinate variable instead of the actual data set. Users should use the routine SDiscoordvar to determine whether the given data set is a coordinate variable.

The value of sds_index is greater than or equal to 0 and less than the number of data sets in the file. The total number of data sets in a file may be obtained from a call to SDfileinfo. The SDnametoindex routine can be used to find the index of a data set if its name is known.

FORTRAN

integer function sfselect(sd_id, sds_index)

integer sd_id, sds_index



[Back to Interface] [Prev] [Next]

hdfhelp@ncsa.uiuc.edu
HDF Reference Manual - 07/29/98, NCSA HDF Development Group.