The Grammar of Graphics for single-cell omics.
pip install cellestialCellestial is an interactive and a highly customizable Single-Cell & Spatial omics data visualization library. Built on top Lets-Plot, it offers a ggplot-like layered and modular approach offering high customizability and publication-ready figures.
Cellestial is highly integrated with scverse's AnnData with room for integration with any upcoming single-cell omics data type in the Python single-cell omics ecosystem.
Cellestial leverages the performance of Polars ensuring speed and scalability.
Cellestial is built-on top the following core design philosophies:
- Modularity over abstraction
- Predictability over flexibility
- Explicity over implicity
- Simplicity & Expressiveness
with reproduciblity, intiutiveness & ease-of-use, and, of course, beautiful publication-ready plots/charts/figures in mind.
To see the example Figures visit Cellestial Webpage.
import cellestial as clumap = cl.umap(
data,
key="cell_type_lvl1",
size=1,
axis_type="arrow",
alpha=0.6,
tooltips=["cell_type_lvl1", "n_genes","pct_counts_in_top_50_genes"],
legend_ondata=True,
ondata_size=12,
ondata_fontface="bold",
ondata_family="mono",
ondata_alpha=0.8,
)The ggplot-like API allows adding layers and customizing the plot.
# modify plot size and color palette
umap += ggsize(800, 600) + scale_color_hue()
# highlight clusters
umap + cl.cluster_outlines(dim,["B Cells","Erythroid"])TODO
Instead of singular function names (umap), multi/grid plots requires the plural (umaps),providing predictability which guarentees the reproducibility.
Which are valid for all dimensional subsets (expression,pca,umap, tsne).
cl.umaps(
data,
keys=["leiden", "HBD", "NEAT1", "IGKC"],
ncol=2,
size=1,
color_high="red",
) + ggsize(900, 600)



