Learn R Programming

Seurat (version 5.0.3)

writing-integration: Writing Integration Method Functions

Description

Integration method functions can be written by anyone to implement any integration method in Seurat. These methods should expect to take a v5 assay as input and return a named list of objects that can be added back to a Seurat object (eg. a dimensional reduction or cell-level meta data)

Arguments

Provided Parameters

Every integration method function should expect the following arguments:

  • object”: an Assay5 object

  • orig”: dimensional reduction to correct

  • layers”: names of normalized layers in object

  • scale.layer”: name(s) of scaled layer(s) in object

  • features”: a vector of features for integration

  • groups”: a one-column data frame with the groups for each cell in object; the column name will be “group”

Method Discovery

The documentation for IntegrateLayers() will automatically link to integration method functions provided by packages in the search() space. To make an integration method function discoverable by the documentation, simply add an attribute named “Seurat.method” to the function with a value of “integration


attr(MyIntegrationFunction, which = "Seurat.method") <- "integration"

See Also

IntegrateLayers()