lamindb.integrations.save_tiledbsoma_experiment

lamindb.integrations.save_tiledbsoma_experiment(adatas, key=None, description=None, run=None, revises=None, measurement_name='RNA', obs_id_name='obs_id', var_id_name='var_id', append_obsm_varm=False, **kwargs)

Write AnnData to tiledbsoma.Experiment.

Reads AnnData objects, writes them to tiledbsoma.Experiment, creates & saves an {class}`~lamindb.Artifact`.

Populates a column lamin_run_uid column in obs with the current run.uid.

Is based on tiledbsoma.io.from_anndata.

Parameters:
  • adatas (list[AnnData | UPathStr]) – AnnData objects to write, in-memory or on-disk.

  • key (str | None, default: None) – An optional key to reference the artifact.

  • description (str | None, default: None) – A description.

  • run (Run | None, default: None) – The run that creates the artifact.

  • revises (Artifact | None, default: None) – lamindb.Artifact with tiledbsoma.Experiment to append to.

  • measurement_name (str, default: 'RNA') – The name of the measurement to store data in tiledbsoma.Experiment.

  • obs_id_name (str, default: 'obs_id') – Which AnnData obs column to use for append mode.

  • var_id_name (str, default: 'var_id') – Which AnnData var column to use for append mode.

  • append_obsm_varm (bool, default: False) – Whether to append obsm and varm in append mode .

  • **kwargs – Keyword arguments passed to tiledbsoma.io.from_anndata.

Return type:

Artifact