Skip to contents

Run Seurat analysis

Usage

runSeurat(object, ...)

# S4 method for Seurat
runSeurat(
  object,
  regressCellCycle = c("s-g2m-diff", "yes", "no"),
  varsToRegress = c("nCount_RNA", "mitoRatio"),
  dims = "auto",
  resolution = seq(from = 0.2, to = 1.2, by = 0.2),
  workers = "auto"
)

# S4 method for SingleCellExperiment
runSeurat(object, ...)

Arguments

object

Object.

...

Additional arguments.

regressCellCycle

character(1).

  • "s-g2m-diff": Calculate the difference between S and G2/M phases and use that to regress. See CC.Difference metric in Seurat vignette.

  • "yes": Regress out any effects of both S and G2/M phase variable. Refer to "S.Score" and "G2M.Score" metrics in Seurat vignette.

  • "no": Don't calculate cell-cycle scoring and don't regress.

Refer to the Seurat cell-cycle regression vignette for details.

varsToRegress

character or NULL. Unwanted sources of variance to regress. Note that when regressCellCycle is not "no", then the corresponding cell-cycle variables are added automatically. Passes to Seurat::ScaleData internally.

dims

"auto" or integer. Dimensions of reduction to use as input for shared nearest neighbor (SNN) graph construction. When set to "auto" (default), the elbow point is calculated internally. See plotPcElbow() for details. Passes to Seurat::FindNeighbors() and Seurat::RunUMAP() internally.

resolution

numeric. Resolutions to calculate for clustering. Passes to Seurat::FindClusters() internally.

Currently supported:

  • "uwot", changed to default in Seurat 3. Note that this sets metric = "cosine" automatically.

  • "umap-learn", which requires reticulate. Note that this sets metric = "correlation" automatically.

workers

"auto", integer(1), or NULL. Disable parallelization with future by setting to NULL.

Value

Seurat.

Note

Updated 2023-09-21.

See also

  • https://github.com/satijalab/seurat/wiki

  • https://satijalab.org/seurat/essential_commands.html

  • https://satijalab.org/seurat/v3.1/cell_cycle_vignette.html https://satijalab.org/seurat/v3.0/future_vignette.html

  • https://satijalab.org/seurat/v3.1/pbmc3k_tutorial.html