SOMAExperiment
is a specialized SOMACollection
,
representing one or more modes of measurement across a single collection of
cells (aka a "multimodal dataset") with pre-defined fields: obs
and ms
(see Active Bindings below for details). (lifecycle: maturing)
Adding new objects to a collection
The SOMAExperiment
class provides a number of type-specific methods for
adding new a object to the collection, such as add_new_sparse_ndarray()
and
add_new_dataframe()
. These methods will create the new object and add it as
member of the SOMAExperiment
. The new object will always inherit the parent
context (see SOMATileDBContext
) and, by default, its platform
configuration (see PlatformConfig
). However, the user can override the
default platform configuration by passing a custom configuration to the
platform_config
argument.
Super classes
tiledbsoma::TileDBObject
-> tiledbsoma::TileDBGroup
-> tiledbsoma::SOMACollectionBase
-> SOMAExperiment
Active bindings
obs
a
SOMADataFrame
containing primary annotations on the observation axis. The contents of thesoma_joinid
column define the observation index domain,obs_id
. All observations for theSOMAExperiment
must be defined in this dataframe.ms
a
SOMACollection
of namedSOMAMeasurement
s.
Methods
Inherited methods
tiledbsoma::TileDBObject$class()
tiledbsoma::TileDBObject$exists()
tiledbsoma::TileDBObject$is_open()
tiledbsoma::TileDBObject$mode()
tiledbsoma::TileDBObject$reopen()
tiledbsoma::TileDBGroup$close()
tiledbsoma::TileDBGroup$get_metadata()
tiledbsoma::TileDBGroup$length()
tiledbsoma::TileDBGroup$names()
tiledbsoma::TileDBGroup$open()
tiledbsoma::TileDBGroup$print()
tiledbsoma::TileDBGroup$remove()
tiledbsoma::TileDBGroup$set_metadata()
tiledbsoma::TileDBGroup$to_data_frame()
tiledbsoma::TileDBGroup$to_list()
tiledbsoma::SOMACollectionBase$add_new_collection()
tiledbsoma::SOMACollectionBase$add_new_dataframe()
tiledbsoma::SOMACollectionBase$add_new_dense_ndarray()
tiledbsoma::SOMACollectionBase$add_new_sparse_ndarray()
tiledbsoma::SOMACollectionBase$create()
tiledbsoma::SOMACollectionBase$get()
tiledbsoma::SOMACollectionBase$initialize()
tiledbsoma::SOMACollectionBase$set()
Method axis_query()
Subset and extract data from a SOMAMeasurement
by
querying the obs
/var
axes.
Arguments
measurement_name
The name of the measurement to query.
obs_query, var_query
An
SOMAAxisQuery
object for the obs/var axis.
Returns
A SOMAExperimentAxisQuery
object.
Method update_obs()
Update the obs SOMADataFrame
to add or remove columns.
See SOMADataFrame$update()
for details.
Arguments
values
A
data.frame
,arrow::Table
, orarrow::RecordBatch
.row_index_name
An optional scalar character. If provided, and if the
values
argument is adata.frame
with row names, then the row names will be extracted and added as a new column to thedata.frame
prior to performing the update. The name of this new column will be set to the value specified byrow_index_name
.
Method update_var()
Update the var SOMADataFrame
to add or remove columns.
See SOMADataFrame$update()
for details.
Arguments
values
A
data.frame
,arrow::Table
, orarrow::RecordBatch
.measurement_name
The name of the
SOMAMeasurement
whosevar
will be updated.row_index_name
An optional scalar character. If provided, and if the
values
argument is adata.frame
with row names, then the row names will be extracted and added as a new column to thedata.frame
prior to performing the update. The name of this new column will be set to the value specified byrow_index_name
.