muon.prot.pp.clr#
- muon.prot.pp.clr(adata: AnnData, inplace: bool = True, axis: Literal[0, 1] = 0, flavor: Literal['seurat', 'stoeckius', 'standard'] = 'seurat') AnnData | None#
Apply the centered log ratio (CLR) transformation to normalize counts in adata.X.
- Parameters:
data – AnnData object with protein expression counts.
inplace – Whether to update adata.X inplace.
axis – Axis across which CLR is performed.
flavor –
How to perform the CLR transformation.
- seurat: Uses log1p transformations throughout. This results in non-negative values and preserves
sparse matrices.
- stoeckius: Follows the original CITE-Seq paper by adding a pseudocount of 1 to the data before
performing any transformations and using the standard log transform. This adheres more closely to the standard definition of the CLR transform, but can yield negative values and does not preserve sparse matrices (the result is always a dense matrix.)
- standard: The standard CLR transform without any pseudocounts. Does not preserve sparse matrices
and may yield infinite values if the input contains zeros.
References
Stoeckius et al, 2017 (doi:10.1038/nmeth.4380)