napari_prism.pp.scale

Contents

napari_prism.pp.scale#

napari_prism.pp.scale(adata, layer=None, copy=True, **kwargs)#

Scale columns and rows to have 0 mean and unit variance in a given layer or .X. Wraps scanpy.pp.scale or rsc.pp.scale.

Parameters:
  • adata (AnnData) – Anndata object.

  • layer (Optional[str] (default: None)) – Expression layer to apply scale transformation. If None, X is transformed.

  • copy (bool (default: True)) – Return a copy instead of writing inplace.

  • **kwargs – Additional keyword arguments to pass to pp.scale.

Return type:

AnnData | None

Returns:

AnnData object with scale transformation applied. If copy is False, modifies the AnnData object in place and returns None