make_asurat_obj: Make an ASURAT object.

Description Usage Arguments Details Value Examples

View source: R/utils.R

Description

This function creates an ASURAT object.

Usage

1
make_asurat_obj(mat_expression, gene_symbol, gene_entrez, sample_identity)

Arguments

mat_expression

A numeric matrix or data frame of raw read counts, where rows and columns stand for genes and samples, respectively.

gene_symbol

A one-dimensional vector of gene symbols.

gene_entrez

A one-dimensional vector of Entrez gene IDs.

sample_identity

A one-dimensional vector of sample identities.

Details

An ASURAT object consists of history, variable, sample, and data slots at the beginning, and several others in the future. Here, the parameters of ASURAT's functions that users run are recorded in history, while information of genes, samples, and gene expression matrices are written in variable, sample, and data, respectively.

Value

An ASURAT object in the form of a list.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
mat_expression <- matrix(1:12, nrow = 3, ncol = 4)
gene_symbol <- data.frame(c("gene_A", "gene_B", "gene_C"))
gene_entrez <- data.frame(c("1", "2", "3"))
sample_identity <- data.frame(c("cell_1", "cell_2", "cell_3", "cell_4"))
myobj <- asurat_make_obj(
  mat_expression = mat_expression,
  gene_symbol = gene_symbol,
  gene_entrez = gene_entrez,
  sample_identity = sample_identity
)

johannesnicolaus/ASURAT_source documentation built on Dec. 21, 2021, 2:11 a.m.