Skip to contents

Implementation of an HDF5-backed AnnData object.

See AnnData-usage for details on creating and using AnnData objects.

See also

AnnData-usage for details on creating and using AnnData objects

Other AnnData classes: AbstractAnnData, InMemoryAnnData

Super class

anndataR::AbstractAnnData -> HDF5AnnData

Active bindings

X

See AnnData-usage

layers

See AnnData-usage

obsm

See AnnData-usage

varm

See AnnData-usage

obsp

See AnnData-usage

varp

See AnnData-usage

obs

See AnnData-usage

var

See AnnData-usage

obs_names

See AnnData-usage

var_names

See AnnData-usage

uns

See AnnData-usage

Methods

Inherited methods


Method new()

Close the HDF5 file when the object is garbage collected

HDF5AnnData constructor

Usage

HDF5AnnData$new(
  file,
  X = NULL,
  obs = NULL,
  var = NULL,
  layers = NULL,
  obsm = NULL,
  varm = NULL,
  obsp = NULL,
  varp = NULL,
  uns = NULL,
  shape = NULL,
  mode = c("a", "r", "r+", "w", "w-", "x"),
  compression = c("none", "gzip", "lzf")
)

Arguments

file

The file name (character) of the .h5ad file. If this file already exits, other arguments must be NULL.

X

See the X slot in AnnData-usage

obs

See the obs slot in AnnData-usage

var

See the var slot in AnnData-usage

layers

See the layers slot in AnnData-usage

obsm

See the obsm slot in AnnData-usage

varm

See the varm slot in AnnData-usage

obsp

See the obsp slot in AnnData-usage

varp

See the varp slot in AnnData-usage

uns

See the uns slot in AnnData-usage

shape

Shape tuple (e.g. c(n_obs, n_vars)). Can be provided if both X or obs and var are not provided.

mode

The mode to open the HDF5 file. See as_HDF5AnnData() for details

compression

The compression algorithm to use. See as_HDF5AnnData() for details

Details

The constructor creates a new HDF5 AnnData interface object. This can either be used to either connect to an existing .h5ad file or to create a new one. If any additional slot arguments are set an existing file will be overwritten.


Method close()

Close the HDF5 file

Usage

HDF5AnnData$close()


Method n_obs()

See the n_obs field in AnnData-usage

Usage

HDF5AnnData$n_obs()


Method n_vars()

See the n_vars field in AnnData-usage

Usage

HDF5AnnData$n_vars()