18 Interoperability

By this point in the book, one message should already be clear: sclet treats SingleCellExperiment as the central object, but it does not assume that users live in one ecosystem forever. Real projects often move between Seurat, Bioconductor, and Python-based workflows.

This chapter explains how sclet handles that reality. The goal is not just file conversion for its own sake, but a workflow in which data can move across ecosystems without losing clarity about what the object represents and how it should be used next.

18.1 Seurat and SCE Conversion

sclet provides simple conversion helpers between Seurat and SCE objects.

library(sclet)

# SCE to Seurat
# seurat_obj <- as.Seurat(sce_obj)

# Seurat to SCE
# sce_obj <- as.SCE(seurat_obj)

18.2 AnnData (h5ad)

Python’s AnnData format (.h5ad) is widely used. sclet uses zellkonverter-based helpers to provide easy read/write functions.

# Read h5ad
# sce <- ReadH5AD("path/to/data.h5ad")

# Write h5ad
# WriteH5AD(sce, "path/to/output.h5ad")

This allows you to easily move data between R and Python environments, leveraging the best tools from both ecosystems (e.g. sclet/Bioconductor in R and scanpy in Python).