Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
5.5.1 - Français

Change language to:
English - 日本語 - Português - Русский

Please note that the recommended version of Scilab is 2025.0.0. This page might be outdated.
See the recommended documentation of this function

Aide de Scilab >> HDF5 Management > h5readattr

h5readattr

Read the data of an HDF5 attribute

Calling Sequence

h5readattr(obj [, location], name)
h5readattr(filename, location, name)

Arguments

obj

a H5Object

name

a string giving the path to the attribute name

location

a string giving the path to the group or the dataset containing the attribute

filename

a string giving the filename

Description

Read the content of an attribute.

Examples

x = int8(matrix(1:80, 10, 8));
save(TMPDIR + "/x.sod", "x"); // SOD files are HDF5 ones 	

// Open the created file
a = h5open(TMPDIR + "/x.sod");

// Read an attribute of the root group
scilab_version = h5readattr(a, "/", "SCILAB_scilab_version")

// and another one
sod_version = h5readattr(a.root, "SCILAB_sod_version")

// and one from a dataset
scilab_class = h5readattr(a.root.x, "SCILAB_Class")

// We have finished so we free all the resources
h5close(a);

See Also

  • h5read — Read the data of HDF5 dataset
  • h5writeattr — Write an attribute in a group or a dataset
  • h5attr — Create an attribute

History

VersionDescription
5.5.0 HDF5 module introduced.
Report an issue
<< h5read HDF5 Management h5rm >>

Copyright (c) 2022-2024 (Dassault Systèmes)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Thu Oct 02 13:54:34 CEST 2014