normalizeCounts | R Documentation |
Normalizes the count matrix of a molecular assay.
normalizeCounts(
object,
method = "LogNormalize",
mtr_name_new = method,
activate = TRUE,
assay_name = activeAssay(object),
overwrite = FALSE,
verbose = NULL,
...
)
object |
An object of class |
method |
Character value. The normalization method. One of c('LogNormalize',
'CLR', 'RC', 'SCT'). 'SCT' normalization is used for MERFISH and Xenium datasets,
as suggested in the |
mtr_name_new |
Character value. The name under which the new processed matrix
is stored in the |
activate |
Logical. If |
assay_name |
Only relevant if the |
overwrite |
Logical value. Must be |
verbose |
Logical. If (Warning messages will always be printed.) |
... |
Additional arguments given to |
The function creates a temporary Seurat
object and calls Seurat::NormalizeData()
with the corresponding method. Afterwards, the normalized matrix is extracted and
stored in the SPATA2
object with the name specified in mtr_name_new
. This name, in
turn, default to the character value of method
.
The updated input object, containing the added, removed or computed results.
library(SPATA2)
library(tidyverse)
data("example_data")
object <- example_data$object_UKF275T_diet
object <- normalizeCounts(object, method = "LogNormalize")
# default name for processed matrix is the input for `method`
mtr <- getMatrix(object, mtr_name = "LogNormalize")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.