harreman.plots.plot_ct_interacting_cell_scores#
- harreman.plots.plot_ct_interacting_cell_scores(adata, deconv_adata=None, cell_type_pair=None, interactions=None, coords_obsm_key=None, test=None, agg_only=False, normalize_values=False, sample_specific=False, s=None, vmin=None, vmax=None, figsize=(10, 10), cmap='Reds', colorbar=True, swap_y_axis=False)[source]#
Plot cell-type–specific interacting cell scores (for gene pairs or metabolites) across spatial coordinates.
- Parameters:
adata (AnnData) – AnnData containing per-cell-type interaction scores.
deconv_adata (AnnData, optional) – If provided, interaction results are copied from this object into adata.
cell_type_pair (list of str or list of tuple) – Cell type pairs to visualize - tuple: (“T cell”, “Macrophage”) - string: “T cell” (matches any pair containing this cell type)
interactions (list of str) – Gene pairs or metabolites to visualize.
coords_obsm_key (str) – Key for spatial coordinates in
obsm.test ({"parametric", "non-parametric"}) – Statistical test used during computation.
agg_only (bool, default False) – Whether to plot only aggregated per-cell-type interactions.
normalize_values (bool, default False) – Apply min–max normalization to each column.
sample_specific (bool, default False) – Plot one figure per sample.
s (float) – Dot size.
vmin (float or str ("p5"), optional) – Color scale limits; percentiles allowed.
vmax (float or str ("p5"), optional) – Color scale limits; percentiles allowed.
figsize (tuple, default (10,10)) – Figure size.
cmap (str, default "Reds") – Colormap for plotting.
colorbar (bool, default True) – Whether to display the colorbar.
swap_y_axis (bool, default False) – Flip y-axis orientation.