mantispy.ds.pki

Contents

mantispy.ds.pki#

mantispy.ds.pki(plates=None, cache_dir=None, *, aggregated=False, feature_selected=False)[source]#

Kinase inhibitors over a dose series, from the JUMP pilot.

cpg0008-pki: fifteen compounds over a seven-point dose range (eleven at three doses, four at one) in U2OS cells, over eight plates with 32 to 64 replicate wells per treatment.

The base and its variants are pre-built by scripts/build_staged_datasets.py from the eight raw plate tables and rehosted on scverse-exampledata, so the loader fetches a single h5ad rather than reassembling the base on every call. The two flags select the variant:

  • both False: the raw wells with every feature, the object the recipe tutorials start from.

  • feature_selected=True: the well-level block after pycytominer-default feature selection.

  • aggregated=True: one modz consensus (Spearman, min_replicates=2) per Metadata_Perturbation over every well, DMSO included, so each compound-at-dose is one profile.

  • aggregated=True, feature_selected=True: that same consensus on the feature-selected block.

Parameters:
  • plates (Sequence[str] | None (default: None)) – Plate barcodes to load, all eight when omitted. Only applies to the base; the hosted base is fetched once and subset to these plates in memory.

  • cache_dir (str | Path | None (default: None)) – Where to keep the download. Defaults to mantispy.settings.cache_dir.

  • aggregated (bool (default: False)) – Return the perturbation-level modz consensus instead of the wells.

  • feature_selected (bool (default: False)) – Return the feature-selected block instead of all features.

Return type:

AnnData

Returns:

Wells by features at well resolution when both flags are False, else the staged variant selected by the two flags, read with mantispy.io.read(), with Metadata_Perturbation (compound at concentration), Metadata_Perturbation_Type ("compound"), Metadata_Compound, Metadata_Concentration (the platemap’s mmoles_per_liter), Metadata_MOA, Metadata_Control, Metadata_CellCount and Metadata_SiteCount.

Raises:
  • KeyError – A plate is not one of the eight.

  • ValueError – aggregated or feature_selected is not a bool, or plates is given for a variant.

Notes

Metadata_Control marks the DMSO wells only. The positive controls (Metadata_control_type == "poscon") are not flagged, because they are perturbations and should not be normalized against.