PrepSCTIntegration: Prepare an object list normalized with sctransform for...

Description Usage Arguments Value Examples

View source: R/integration.R

Description

This function takes in a list of objects that have been normalized with the SCTransform method and performs the following steps:

Usage

1
2
3
4
5
6
7
PrepSCTIntegration(
  object.list,
  assay = NULL,
  anchor.features = 2000,
  sct.clip.range = NULL,
  verbose = TRUE
)

Arguments

object.list

A list of Seurat objects to prepare for integration

assay

The name of the Assay to use for integration. This can be a single name if all the assays to be integrated have the same name, or a character vector containing the name of each Assay in each object to be integrated. The specified assays must have been normalized using SCTransform. If NULL (default), the current default assay for each object is used.

anchor.features

Can be either:

  • A numeric value. This will call SelectIntegrationFeatures to select the provided number of features to be used in anchor finding

  • A vector of features to be used as input to the anchor finding process

sct.clip.range

Numeric of length two specifying the min and max values the Pearson residual will be clipped to

verbose

Display output/messages

Value

A list of Seurat objects with the appropriate scale.data slots containing only the required anchor.features.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
## Not run: 
# to install the SeuratData package see https://github.com/satijalab/seurat-data
library(SeuratData)
data("panc8")

# panc8 is a merged Seurat object containing 8 separate pancreas datasets
# split the object by dataset and take the first 2 to integrate
pancreas.list <- SplitObject(panc8, split.by = "tech")[1:2]

# perform SCTransform normalization
pancreas.list <- lapply(X = pancreas.list, FUN = SCTransform)

# select integration features and prep step
features <- SelectIntegrationFeatures(pancreas.list)
pancreas.list <- PrepSCTIntegration(
  pancreas.list,
  anchor.features = features
)

# downstream integration steps
anchors <- FindIntegrationAnchors(
  pancreas.list,
  normalization.method = "SCT",
  anchor.features = features
)
pancreas.integrated <- IntegrateData(anchors)

## End(Not run)

ibseq/scs-analysis documentation built on Feb. 27, 2021, 12:35 a.m.