harreman.plots.plot_interacting_cell_scores#
- harreman.plots.plot_interacting_cell_scores(adata, interactions=None, coords_obsm_key=None, test=None, only_sig_values=False, use_FDR=True, 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 spatial maps of interacting cell scores for selected gene pairs or metabolites.
- Parameters:
adata (AnnData) – Must contain interacting cell statistics in:
uns['interacting_cell_results'][test]['gp'/'m'].interactions (list of str) – Gene pairs or metabolites to plot.
coords_obsm_key (str) – Key in
adata.obsmcontaining spatial coordinates.test ({"parametric", "non-parametric"}) – Determines which statistical results to load.
only_sig_values (bool, default False) – If True, plot only significant values (FDR or p-value).
use_FDR (bool, default True) – If
only_sig_values=True, choose FDR instead of raw p-values.normalize_values (bool, default False) – Apply per-interaction min–max normalization.
sample_specific (bool, default False) – Plot each sample separately, using
uns['sample_key'].s (float) – Dot size.
vmin (float or str ("p5", "p95"), optional) – Color scale limits; percentiles allowed.
vmax (float or str ("p5", "p95"), optional) – Color scale limits; percentiles allowed.
figsize (tuple, default (10,10)) – Figure size.
cmap (str, default "Reds") – Colormap for the score intensity.
colorbar (bool, default True) – Show or hide the colorbar.
swap_y_axis (bool, default False) – Flip the y-axis for visualization conventions.