squidpy.pl.centrality_scores
- squidpy.pl.centrality_scores(adata, cluster_key, score=None, legend_kwargs=mappingproxy({}), palette=None, figsize=None, dpi=None, save=None, **kwargs)[source]
Plot centrality scores.
The centrality scores are computed by
squidpy.gr.centrality_scores()
.- Parameters:
adata (
AnnData
) – Annotated data object.cluster_key (
str
) – Key inanndata.AnnData.obs
where clustering is stored.score (
Union
[str
,Sequence
[str
],None
]) – Whether to plot all scores or only selected ones.legend_kwargs (
Mapping
[str
,Any
]) – Keyword arguments formatplotlib.pyplot.legend()
.palette (
Union
[str
,ListedColormap
,None
]) – Categorical colormap for the clusters. IfNone
, useanndata.AnnData.uns
['{cluster_key}_colors']
, if available.figsize (
Optional
[tuple
[float
,float
]]) – Size of the figure in inches.scalebar_kwargs – Keyword arguments for
matplotlib_scalebar.ScaleBar()
.edges_kwargs – Keyword arguments for
networkx.draw_networkx_edges()
.kwargs (
Any
) – Keyword arguments formatplotlib.pyplot.scatter()
ormatplotlib.pyplot.imshow()
.
- Return type:
- Returns:
: Nothing, just plots the figure and optionally saves the plot.