pegasus.correct_batch¶
-
pegasus.
correct_batch
(data, features=None)[source]¶ Batch correction on data using Location-Scale (L/S) Adjustment method. ([Li-and-Wong03], [Li20]). If L/S adjustment method is used, users must call this function every time before they call the pca function.
- Parameters
data (
pegasusio.MultimodalData
) – Annotated data matrix with rows for cells and columns for genes.features (str, optional, default:
None
) – Features to be included in batch correction computation. IfNone
, simply consider all features.
- Return type
None
- Returns
None
Update
data.X
by the corrected count matrix.
Examples
>>> pg.correct_batch(data, features = "highly_variable_features")