scPyviewer.plot_matrixplot#
- scPyviewer.plot_matrixplot(ds, genes, group=None, figsize=None, dpi=150, cmap='Blues', vmin=None, vmax=None, standard_scale=None, swap_axes=False, annotate=False, annotation_fmt='.2f', annotation_fontsize=7, title=None, title_fontsize=11, xlabel=None, ylabel=None, xlabel_fontsize=9, ylabel_fontsize=9, tick_fontsize=8, gene_label_rotation=45, colorbar_label=None, colorbar_fontsize=8, font_family=None)[source]#
Mean-expression matrix heatmap: groups × genes.
Better than
sc.pl.matrixplot: directfigsize/dpiand full font control.annotate=Trueoverlays the numeric mean in each cell.- Parameters:
group (str, optional) –
obscolumn for row-grouping.figsize (tuple, optional) – Figure
(width, height)in inches. Auto if None.dpi (int) – Resolution.
cmap (str) – Colormap.
vmax (float | None) – Color-scale limits.
standard_scale ({None, "var", "group"}) – Normalize per gene (
"var") or per group ("group").swap_axes (bool) – Transpose: genes on Y, groups on X.
annotate (bool) – Overlay numeric mean-expression values in each cell.
annotation_fmt (str) – Python format string for annotations (e.g.
".2f").annotation_fontsize (float) – Font size of annotation text.
title (str, optional) – Figure title.
title_fontsize (float) – Title font size.
ylabel (str | None) – Axis label overrides.
ylabel_fontsize (float) – Axis label font sizes.
tick_fontsize (float) – Tick-label font size.
gene_label_rotation (int) – Gene label rotation in degrees.
colorbar_label (str, optional) – Override colorbar label.
colorbar_fontsize (float) – Colorbar text size.
font_family (str, optional) – Font family for this figure only.
ds (Dataset)
vmin (float | None)
vmax
xlabel (str | None)
ylabel
xlabel_fontsize (float)
ylabel_fontsize