Skip to content

Commit 43f6011

Browse files
docs: add inline example plot to sc.pl.correlation_matrix (#4059)
1 parent 1970446 commit 43f6011

1 file changed

Lines changed: 9 additions & 4 deletions

File tree

src/scanpy/plotting/_anndata.py

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1783,10 +1783,15 @@ def correlation_matrix( # noqa: PLR0912, PLR0913, PLR0915
17831783
17841784
Examples
17851785
--------
1786-
>>> import scanpy as sc
1787-
>>> adata = sc.datasets.pbmc68k_reduced()
1788-
>>> sc.tl.dendrogram(adata, "bulk_labels")
1789-
>>> sc.pl.correlation_matrix(adata, "bulk_labels")
1786+
Plot correlation matrix between cell type groups.
1787+
1788+
.. plot::
1789+
:context: close-figs
1790+
1791+
import scanpy as sc
1792+
adata = sc.datasets.pbmc68k_reduced()
1793+
sc.tl.dendrogram(adata, "bulk_labels")
1794+
sc.pl.correlation_matrix(adata, "bulk_labels")
17901795
17911796
"""
17921797
dendrogram_key = _get_dendrogram_key(adata, _dk(dendrogram), groupby)

0 commit comments

Comments
 (0)