matlab-stdlib

Matlab stdlib API

The API is broken up into modules:

stdlib.fileio

These functions are in namespace:

import stdlib.fileio.*

HDF5: stdlib.hdf5nc

Check HDF5 version built into Matlab:

[major,minor,rel] = H5.get_libversion()

These functions are in namespace:

import stdlib.hdf5nc.*

h5save: Save a variable to an HDF5 dataset. If dataset exists, the existing dataset shape must match the variable.

h5save(filename, dataset_name, dataset)

The shape of the dataset can be controlled by specifying the “size” argument. This is particularly useful when writing HDF5 files to be used in other programming languages where dimensional shapes are important. Matlab may collapse singleton dimensions otherwise.

h5save(filename, dataset_name, dataset, size=[3,1])

Likewise, the type of the dataset may be explicitly specified with the “type” argument:

h5save(filename, dataset_name, dataset, type="int32")

NetCDF4: stdlib.hdf5nc

Check NetCDF4 version built into Matlab:

netcdf.inqLibVers

These functions are in namespace:

import stdlib.hdf5nc.*

Save a variable to a dataset. If dataset exists, the existing dataset shape must match the variable.

ncsave(filename, variable_name, variable)

system: stdlib.sys