Learn R Programming

Seurat (version 3.1.0)

GetAssayData: General accessor function for the Assay class

Description

This function can be used to pull information from any of the slots in the Assay class. For example, pull one of the data matrices("counts", "data", or "scale.data").

Usage

GetAssayData(object, ...)

# S3 method for Assay GetAssayData(object, slot = "data", ...)

# S3 method for Seurat GetAssayData(object, slot = "data", assay = NULL, ...)

Arguments

object

An object

...

Arguments passed to other methods

slot

Specific information to pull (i.e. counts, data, scale.data, ...)

assay

Name of assay to pull data from

Value

Returns info from requested slot

Examples

Run this code
# NOT RUN {
# Get the data directly from an Assay object
GetAssayData(object = pbmc_small[["RNA"]], slot = "data")[1:5,1:5]

# Get the data from a specific Assay in a Seurat object
GetAssayData(object = pbmc_small, assay = "RNA", slot = "data")[1:5,1:5]

# }

Run the code above in your browser using DataLab