dynamo.pl.basic_stats

dynamo.pl.basic_stats(adata, group=None, figsize=(4, 3), save_show_or_return='show', save_kwargs={})[source]

Plot the basic statics (nGenes, nCounts and pMito) of each category of adata.

Parameters:
  • adata (AnnData) – an AnnData object.

  • group (Optional[str]) – the column key of adata.obs to facet the data into subplots. If None, no faceting will be used. Defaults to None.

  • figsize (Tuple[float, float]) – the size of each panel in the figure. Defaults to (4, 3).

  • save_show_or_return (Literal['save', 'show', 'return']) – whether to save, show, or return the plots. Could be one of ‘save’, ‘show’, or ‘return’. Defaults to “show”.

  • save_kwargs (Dict[str, Any]) – a dictionary that will be passed to the save_show_ret function. By default, it is an empty dictionary and the save_show_ret function will use the {“path”: None, “prefix”: ‘basic_stats’, “dpi”: None, “ext”: ‘pdf’, “transparent”: True, “close”: True, “verbose”: True} as its parameters. Otherwise, you can provide a dictionary that properly modify those keys according to your needs. Defaults to {}.

Return type:

Optional[FacetGrid]

Returns:

None would be returned by default. If save_show_or_return is set to ‘return’, the generated figure (seaborn.FacetGrid) would be returned.