snapatac2.pl.umap#

snapatac2.pl.umap(adata, color=None, use_rep='X_umap', marker_size=None, marker_opacity=1, sample_size=None, **kwargs)[source]#

Plot the UMAP embedding.

Parameters:
  • adata (AnnData | np.ndarray) – Annotated data matrix.

  • color (str | np.ndarray | None) – If the input is a string, it will be used the key to retrieve values from obs.

  • use_rep (str) – Use the indicated representation in .obsm.

  • marker_size (float) – Size of the dots.

  • marker_opacity (float) – Opacity of the dots.

  • sample_size (int | None) – If the number of cells is larger than sample_size, a random sample of sample_size cells will be used for plotting.

  • kwargs – Additional arguments passed to render_plot to control the final plot output. Please see render_plot for details.

Returns:

If show=False and out_file=None, an plotly.graph_objects.Figure will be returned, which can then be further customized using the plotly API.

Return type:

‘plotly.graph_objects.Figure’ | None