dynamo.pl.speed(adata, basis='pca', color=None, frontier=True, *args, **kwargs)[source]

Scatter plot with cells colored by the estimated velocity speed (and other information if provided).

  • adata (AnnData) – an Annodata object with speed estimated.

  • basis (str) – the embedding data in which the vector field was reconstructed and RNA speed was estimated. Defaults to “pca”.

  • color (Union[List[str], str, None]) – any column names or gene names, etc. in addition to the curl to be used for coloring cells. Defaults to None.

  • frontier (bool) – whether to add the frontier. Scatter plots can be enhanced by using transparency (alpha) in order to show area of high density and multiple scatter plots can be used to delineate a frontier. See matplotlib tips & tricks cheatsheet (https://github.com/matplotlib/cheatsheets). Originally inspired by figures from scEU-seq paper: https://science.sciencemag.org/content/367/6482/1151. Defaults to True.


Exception – speed information is not found in adata.

Return type:

Union[Axes, List[Axes], Tuple[Axes, List[str], Literal['white', 'black']], Tuple[List[Axes], List[str], Literal['white', 'black']], None]


None would be returned by default. If in kwargs save_show_or_return is set to be ‘return’ or ‘all’, the matplotlib axes object of the generated plots would be returned. If return_all is set to be true, the list of colors used and the font color would also be returned. See docs of dynamo.pl.scatters for more information.