mantispy.pl.outliers

Contents

mantispy.pl.outliers#

mantispy.pl.outliers(adata, key='qc_outlier', groupby='Metadata_Plate', axes=None)[source]#

Outlier score distribution, and the flagged fraction per groupby group.

Parameters:
  • adata (AnnData) – Object outliers() has run on.

  • key (str (default: 'qc_outlier')) – obs column holding the flag, whose score is read from key + "_score".

  • groupby (str (default: 'Metadata_Plate')) – obs column whose groups become the bars, e.g. "Metadata_Well" on a single plate.

  • axes (ndarray | None (default: None)) – A pair of axes to draw into, or None for a new figure.

Return type:

ndarray | None

Returns:

The two axes when the caller passed axes, else None because the plot then owns the figure it created. When returned they are the score histogram split into kept and flagged, and the flagged fraction per group.

Raises:

KeyError – obs has no key column.