R/seuratFunctions.R
runSeuratPCA.Rd
runSeuratPCA Computes PCA on the input sce object and stores the calculated principal components within the sce object
runSeuratPCA(
inSCE,
useAssay = "seuratScaledData",
reducedDimName = "seuratPCA",
nPCs = 20,
features = NULL,
seed = NULL,
verbose = TRUE
)
(sce) object on which to compute PCA
Assay containing scaled counts to use in PCA.
Name of new reducedDims object containing Seurat PCA.
Default seuratPCA
.
numeric value of how many components to compute. Default
20
.
Specify the feature names or rownames which should be used
for computation of PCA. Default is NULL
which will use the previously
stored variable features.
Random seed for reproducibility of results.
Default NULL
will use global seed in use by the R environment.
Logical value indicating if informative messages should
be displayed. Default is TRUE
.
Updated SingleCellExperiment
object which now contains the
computed principal components
data(scExample, package = "singleCellTK")
if (FALSE) {
sce <- runSeuratNormalizeData(sce, useAssay = "counts")
sce <- runSeuratFindHVG(sce, useAssay = "counts")
sce <- runSeuratScaleData(sce, useAssay = "counts")
sce <- runSeuratPCA(sce, useAssay = "counts")
}