Inherits from classH5T.
Object of classH5T_COMPOUND.
new(labels, dtypes, size = NULL, offset = NULL, id = NULL)Create at compound type that is the HDF5 equivalent of a table
Parameters
The labels of the columns of the compound object
The datatypes of the columns of the object; this is usually a list of objectsof classH5T
The size of each datatype; ifNULL, automatically inferred
The offset where each datatype starts; can be different from the sum of the individual sizesso that datatypes are aligned with memory addresses. IfNULL, inferred automatically
Internal use only
pack()This function implements the HDF5-API function H5Tpack.Please see the documentation athttps://docs.hdfgroup.org/hdf5/v1_10/group___h5_t.html for details.
get_cpd_types()ReturnH5T objects that represent the datatypes of the columns of thecompound object. Returned as a list if more than 1
get_cpd_labels()Return the labels of the columns as a character vector
get_cpd_classes()Return the classes of the columns as an object of typefactor_ext
get_cpd_offsets()Return the offsets of the datatypes
describe()Print a detailed description of the datatype; this is experimental
Holger Hoefling
# create a H5T_COMPOUND corresponding to a data-framemy_cpd<-H5T_COMPOUND$new(c("name","age","salary"), dtypes=list(H5T_STRING$new(size=200),h5types$H5T_NATIVE_INT,h5types$H5T_NATIVE_DOUBLE))my_cpd#> Class: H5T_COMPOUND#> Datatype: H5T_COMPOUND {#> H5T_STRING {#> STRSIZE 200;#> STRPAD H5T_STR_NULLTERM;#> CSET H5T_CSET_ASCII;#> CTYPE H5T_C_S1;#> } "name" : 0;#> H5T_STD_I32LE "age" : 200;#> H5T_IEEE_F64LE "salary" : 204;#> }