| h5_is_dataset | R Documentation |
Checks if the object at a given path is a dataset.
h5_is_dataset(file, name, attr = NULL)
file |
The path to the HDF5 file. |
name |
The full path of the object to check. |
attr |
The name of an attribute. If provided, the function returns |
A logical value: TRUE if the object exists and is a dataset,
FALSE otherwise (if it is a group, or does not exist).
h5_is_group(), h5_exists()
file <- tempfile(fileext = ".h5")
h5_write(1, file, "dset")
h5_is_dataset(file, "dset") # TRUE
h5_create_group(file, "grp")
h5_is_dataset(file, "grp") # FALSE
h5_write(1, file, "grp", attr = "my_attr")
h5_is_dataset(file, "grp", "my_attr") # TRUE
unlink(file)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.