Skip to contents

Blockwise reader for SOMASparseNDArray

Super class

tiledbsoma::SOMASparseNDArrayReadBase -> SOMASparseNDArrayBlockwiseRead

Active bindings

axis

The axis to iterate over in a blockwise fashion

Methods


Method new()

Create

Usage

SOMASparseNDArrayBlockwiseRead$new(
  sr,
  array,
  coords,
  axis,
  ...,
  size,
  reindex_disable_on_axis = NA
)

Arguments

sr

SOMA read pointer

array

Underlying SOMASparseNDArray

coords

Optional named list of integer64 values; must be named after array$dimnames()

axis

Axis to iterate over in a blockwise manner

...

Ignored

size

The size of each blockwise chunk to generate

reindex_disable_on_axis

Additional axes that will not be re-indexed; the following values may be used as shorthands for common settings:

  • TRUE”: disable re-indexing on all axes

  • NA”: re-index only on axis, disable re-indexing on all others

  • FALSE”: re-index on all axes, do not disable re-indexing


Method tables()

Read as an Arrow::Table

Usage

SOMASparseNDArrayBlockwiseRead$tables()

Returns

A blockwise iterator yielding chunks as Arrow::Tables


Method sparse_matrix()

Read as a sparse matrix

Usage

SOMASparseNDArrayBlockwiseRead$sparse_matrix(repr = "T")

Arguments

repr

Representation of the sparse matrix to return; choose from:

Note: passing repr of “R” or “C” are only available if re-indexing is enabled on axes 0 or 1, respectively

Returns

A blockwise iterator yielding chunks as sparse matrices