create_empty_h5: Create Empty HDF5 File

View source: R/utilities.R

create_empty_h5R Documentation

Create Empty HDF5 File

Description

This function can be used to create an empty HDF5 file where the user defines the file path and compression level. The empty HDF5 file has under its root group three data slots named 'assay', 'colnames' and 'rownames' for storing a numeric matrix along with its column names (character) and row names (character), respectively.

Usage

create_empty_h5(h5file, delete_existing = FALSE, level = 6)

Arguments

h5file

character(1), path to the HDF5 file to be created

delete_existing

logical, whether to delete an existing HDF5 file with identical path

level

The compression level used, here given as integer value between 0 (no compression) and 9 (highest and slowest compression).

Value

empty HDF5 file

Examples

tmp_file <- tempfile(fileext=".h5")
create_empty_h5(tmp_file, level=6)

yduan004/signatureSearch documentation built on Feb. 19, 2024, 9:30 a.m.