:alt: scplotkit logo
:width: 220px
:align: center
:class: dark-light
A pile of plotting functions for single-cell analysis, built on top of scanpy and AnnData, bundled up so they don't have to be rewritten for every new project.
Masked and highlighted embeddings, gene co-expression blends, compositional
bar plots, pies and heatmaps, dataset overview panels, marker-gene
matrix/violin plots, regression and trend lines, Venn/UpSet set overlaps,
Sankeys/sunbursts/treemaps over annotation hierarchies — all styled
consistently through a single {class}~scplotkit.PlotConfig and saved to disk
with one call. Built-in qualitative palettes (ColorBrewer, Tableau, and
journal-style ones) mean the whole set of figures can be restyled by changing
one name. Nothing statistical, no new analysis, just the plots. PRs for
your own favorite single-cell (or spatial) plots are very welcome.
:maxdepth: 2
:caption: Contents
installation
demonstrations/01_embeddings
demonstrations/02_composition
demonstrations/03_overview
demonstrations/04_markers_and_expression
demonstrations/05_hierarchy_and_enrichment
demonstrations/06_palettes
api
import scanpy as sc
import scplotkit as spk
adata = sc.read_h5ad("my_atlas.h5ad")
plotter = spk.ScPlotter(output_dir="figures")
plotter.masked_umap(adata, color_by="cell_type", mask_values=["CD4 T", "CD8 T"], figure_name="Lymphocytes")
plotter.stacked_barplots(adata, level_column="cell_type", sample_column="sample_id")See the {doc}demonstrations/01_embeddings and the five notebooks that follow it for a walkthrough and
demonstration of major plotting functions, or the {doc}api for the complete function reference.