Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
2024.1.0 - Русский


h5rm

Remove elements from an HDF5 file

Syntax

h5rm(obj [, names])
h5rm(filename, names)

Arguments

obj

a H5Object

names

a matrix of strings giving the locations to remove

filename

a string giving an the path of a HDF5 file

Description

Remove one or more objects from the file.

Examples

a = h5open(TMPDIR + "/test.h5", "a");

// We can create several groups under root
names = "Group_" + string(1:10);
h5group(a, names)

// we display them
h5ls(a)

// ... or
a.root.groups

// we can remove a part of them
names = "Group_" + string(1:2:10);
h5rm(a, names);

// we check that all is ok
a.root.groups

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

// We can remove attributes too
x = %pi;
save(TMPDIR + "/x.sod", "x"); // SOD files are HDF5 ones

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

// we look for attributes
h5ls(a)

// ... or
a.root.attributes

// We remove 'SCILAB_sod_version'
h5rm(a, "SCILAB_sod_version"), h5ls(a)

// Free the resources
h5close(a);

See also

History

ВерсияОписание
5.5.0 HDF5 module introduced.
Report an issue
<< h5readattr HDF5 files h5umount >>

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:
Mon Jun 17 17:55:07 CEST 2024