Skip to contents

Examines the structure and attributes of an HDF5 file to determine what type of fmristore object it contains.

Usage

detect_h5_type(h5obj)

Arguments

h5obj

An H5File object or file path to an HDF5 file

Value

Character string indicating the type, one of: - "H5NeuroVol" - 3D brain volume - "H5NeuroVec" - 4D brain time series - "H5NeuroVecSeq" - Sequence of 4D scans - "H5ParcellatedMultiScan" - Multi-run parcellated experiment - "H5ParcellatedScan" - Single parcellated run (full data) - "H5ParcellatedScanSummary" - Single parcellated run (summary) - "LatentNeuroVec" - Latent representation - "LabeledVolumeSet" - Labeled brain regions - "unknown" - Type could not be determined

Examples

if (FALSE) { # \dontrun{
# Detect type from file path
type <- detect_h5_type("data.h5")

# Detect type from open H5File
h5 <- H5File$new("data.h5", "r")
type <- detect_h5_type(h5)
h5$close_all()
} # }