Perform library size normalization on raw counts input. As for the preprocessing step of iNMF integration, by default we don't multiply the normalized values with a scale factor, nor do we take the log transformation. Applicable S3 methods can be found in Usage section.
normalizePeak
is designed for datasets of "atac" modality, i.e. stored
in ligerATACDataset. S3 method for various container object is
not supported yet due to difference in architecture design.
normalize(object, ...)# S3 method for dgCMatrix
normalize(object, log = FALSE, scaleFactor = NULL, ...)
# S3 method for ligerDataset
normalize(object, chunk = 1000, verbose = getOption("ligerVerbose", TRUE), ...)
# S3 method for liger
normalize(
object,
useDatasets = NULL,
verbose = getOption("ligerVerbose", TRUE),
format.type = NULL,
remove.missing = NULL,
...
)
# S3 method for Seurat
normalize(object, assay = NULL, layer = "counts", save = "ligerNormData", ...)
normalizePeak(
object,
useDatasets = NULL,
verbose = getOption("ligerVerbose", TRUE),
...
)
Updated object
.
dgCMatrix method - Returns processed dgCMatrix object
ligerDataset method - Updates the normData
slot of the object
liger method - Updates the normData
slot of chosen datasets
Seurat method - Adds a named layer in chosen assay (V5), or update the
data
slot of the chosen assay (<=V4)
normalizePeak
- Updates the normPeak
slot of chosen
datasets.
liger object
Arguments to be passed to S3 methods. The "liger" method calls
the "ligerDataset" method, which then calls "dgCMatrix" method.
normalizePeak
directly calls normalize.dgCMatrix
.
Logical. Whether to do a log(x + 1)
transform on the
normalized data. Default TRUE
.
Numeric. Scale the normalized expression value by this
factor before transformation. NULL
for not scaling. Default
1e4
.
Integer. Number of maximum number of cells in each chunk when
working on HDF5 file based ligerDataset. Default 1000
.
Logical. Whether to show information of the progress. Default
getOption("ligerVerbose")
or TRUE
if users have not set.
A character vector of the names, a numeric or logical
vector of the index of the datasets to be normalized. Should specify ATACseq
datasets when using normalizePeak
. Default NULL
normalizes all
valid datasets.
Deprecated. The functionality of these is covered through other parts of the whole workflow and is no long needed. Will be ignored if specified.
Name of assay to use. Default NULL
uses current active
assay.
Where the input raw counts should be from. Default
"counts"
. For older Seurat, always retrieve from counts
slot.
For Seurat>=4.9.9, the name of layer to store normalized data.
Default "ligerNormData"
. For older Seurat, stored to data
slot.