|
Purpose
|
Writes a subsample of data to a data set or to a coordinate variable. |
|
Return value
|
Returns SUCCEED (or 0) if successful and FAIL (or -1) otherwise. |
|
Description
|
SDwritedata writes the specified subsample of data to the data set or coordinate variable identified by the parameter sds_id. The data is written from the buffer buffer. The subsample is defined by the parameters start, stride and edge. |
|
|
The array start specifies the starting position from where the subsample will be written. Valid values of each element in the array start are from 0 to the size of the corresponding dimension of the data set - 1. The dimension sizes are returned by SDgetinfo. |
|
|
The array edge specifies the number of values to write along each data set dimension. |
|
|
The array stride specifies the writing pattern along each dimension. For example, if one of the elements of the array stride is 1, then every element along the corresponding dimension of the data set will be written. If one of the elements of the array stride is 2, then every other element along the corresponding dimension of the data set will be written, and so on. Specifying stride value of NULL in the C interface or setting all values of the array stride to 1 in either interface specifies the contiguous writing of data. If all values in the array stride are set to 0, SDwritedata returns FAIL (or -1). |
|
|
When writing data to a chunked data set using SDwritedata, consideration should be given to be issues presented in the section on chunking in Chapter 3 of the HDF User's Manual, titled Scientific Data Sets (SD API) and Chapter 13 of the HDF User's Manual, titled HDF Performance Issues. |
|
|
Note that there are two FORTRAN-77 versions of this routine; sfwdata and sfwcdata. The sfwdata routine writes numeric data and sfwcdata writes character scientific data. |