as.Seurat: Convert objects to Seurat objects

Description Usage Arguments Details Examples

View source: R/generics.R

Description

Convert objects to Seurat objects

Usage

 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
as.Seurat(x, ...)

## S3 method for class 'CellDataSet'
as.Seurat(x, slot = "counts", assay = "RNA", verbose = TRUE, ...)

## S3 method for class 'loom'
as.Seurat(
  x,
  cells = "CellID",
  features = "Gene",
  normalized = NULL,
  scaled = NULL,
  assay = NULL,
  verbose = TRUE,
  ...
)

## S3 method for class 'SingleCellExperiment'
as.Seurat(
  x,
  counts = "counts",
  data = "logcounts",
  assay = "RNA",
  project = "SingleCellExperiment",
  ...
)

Arguments

x

An object to convert to class Seurat

...

Arguments passed to other methods

slot

Slot to store expression data as

assay

Name to store expression matrices as

verbose

Display progress updates

cells

The name of the dataset within col_attrs containing cell names

features

The name of the dataset within row_attrs containing feature names

normalized

The name of the dataset within layers containing the normalized expression matrix; pass /matrix (with preceeding forward slash) to store /matrix as normalized data

scaled

The name of the dataset within layers containing the scaled expression matrix

counts

name of the SingleCellExperiment assay to store as counts; set to NULL if only normalized data are present

data

name of the SingleCellExperiment assay to slot as data. Set to NULL if only counts are present

project

Project name for new Seurat object

Details

The loom method for as.Seurat will try to automatically fill in a Seurat object based on data presence. For example, if no normalized data is present, then scaled data, dimensional reduction informan, and neighbor graphs will not be pulled as these depend on normalized data. The following is a list of how the Seurat object will be constructed

Examples

1
2
3
4
5
## Not run: 
lfile <- as.loom(x = pbmc_small)
pbmc <- as.Seurat(x = lfile)

## End(Not run)

Seurat documentation built on Jan. 13, 2021, 7:11 p.m.