scSemiProfiler.utils.composition_by_group¶
-
scSemiProfiler.utils.composition_by_group(adata, colormap=None, groupby=None, title='Cell type composition', save=None)[source]¶ Visualizing the cell type composition in each group.
- Parameters
adata (
anndata._core.anndata.AnnData) – The dataset to investigatecolormap (
typing.Union[str,list,None]) – The colormap for visualizationgroupby (
typing.Optional[str]) – The key in .obs specifying groups.title (
str) – Plot titlesave – Path within the ‘figures’ folder to save the plot
- Return type
- Returns
None
Example
>>> groupby = 'states_collection_sum' >>> composition_by_group( >>> adata = gtdata, >>> groupby = groupby, >>> title = 'Ground truth' >>> )