View source: R/Seurat-function.R
RunHarmony2 | R Documentation |
This is a modified version of harmony::RunHarmony specifically designed for compatibility with RunSymphonyMap.
RunHarmony2(object, ...)
## S3 method for class 'Seurat'
RunHarmony2(
object,
group.by.vars,
reduction = "pca",
dims.use = 1:30,
project.dim = TRUE,
reduction.name = "Harmony",
reduction.key = "Harmony_",
verbose = TRUE,
seed.use = 11L,
...
)
object |
A Seurat object. |
... |
Additional arguments to be passed to the RunHarmony function. |
group.by.vars |
A character vector specifying the batch variable name. |
reduction |
A character string specifying the reduction to be used. Default is "pca". |
dims.use |
An integer vector specifying the dimensions to be used. Default is 1:30. |
project.dim |
A logical value indicating whether to project dimension reduction loadings. Default is TRUE. |
reduction.name |
A character string specifying the name of the reduction to be stored in the Seurat object. Default is "Harmony". |
reduction.key |
A character string specifying the prefix for the column names of the Harmony embeddings. Default is "Harmony_". |
verbose |
A logical value indicating whether to print verbose output. Default is TRUE. |
seed.use |
An integer specifying the random seed to be used. Default is 11. |
panc8_sub <- Standard_SCP(panc8_sub)
panc8_sub <- RunHarmony2(panc8_sub, group.by.vars = "tech", reduction = "Standardpca")
CellDimPlot(panc8_sub, group.by = c("tech", "celltype"), reduction = "Standardpca")
CellDimPlot(panc8_sub, group.by = c("tech", "celltype"), reduction = "Harmony")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.