AnnData, use_label: str, lrs: Optional[list] = None, n_top_lrs: int = 5, n_top_ccis: int = 15, min_total: int = 0, ax: Optional[Axes] = None, figsize: tuple = (6.48, 4.8), show: bool = False, cmap: str = 'Spectral_r', square_scaler: int = 700, sig_interactions: bool = True)[source]
Heatmap of interaction counts.

Rows are lrs and columns are celltype->celltype interactions.

  • adata (AnnData) – Data on which & has been applied.

  • use_label (str) – Indicates the cell type labels or deconvolution results used for the cell-cell interaction counting by LR pairs.

  • lrs (list-like) – LR pairs to show in the heatmap, if None then top 5 lrs with highest no. of interactions used from adata.uns[‘lr_summary’].

  • n_top_lrs (int) – Indicates how many top lrs to show; is ignored if lrs is not None.

  • n_top_ccis (int) – Indicates maximum no. of CCIs to show.

  • min_total (int) – Minimum no. of totals interaction celltypes must have to be shown.

  • ax (Axes) – Axes on which to draw the heatmap, is generated internally if None.

  • figsize (tuple) – (width, height), only relevant if ax=None.

  • show (bool) – Whether to show the plot or not, if not returns ax.

  • cmap (str) – Cmap used to color the number of LR interactions.

  • square_scaler (int) – Scaler to size the squares displayed.

  • sig_interactions (bool) – Whether to only show significant CCIs, or all observed interactions.


ax – Axes where the heatmap was drawn on if show=False.

Return type: