next up previous contents
Next: closeDataset Up: Write functions Previous: createSimpleDataset

createSimpleDataset_fmt

hid_t createSimpleDataset (hid_t loc_id, const char* fmt, const char* name, int ndims, hsize_t* dims, void* buf, int compress)

Creates a dataset in an HDF5 file.

Arguments:

loc_id: The group the dataset should be created in.

fmt: A string describing the format of the datatype, e.g. char, short, ...

name: The name that should be used for the dataset.

ndims: The rank of the data to be written.

dims: The dimensions of the data, a pointer to ndims number of hsize_t values.

buf: The data to be written in the dataset, if NULL, an empty dataset will be created.

compress: The compression level on the dataset, betwen 0-9 where 0 is no compression and 9 is highest compression.

Returns -1 on failure, otherwise a hid_t reference to the dataset.




2000-08-08