construct_eset: Construct expression set

View source: R/load_seq.R

construct_esetR Documentation

Construct expression set

Description

Construct expression set

Usage

construct_eset(quants, fdata, annot)

Arguments

quants

DGEList with RNA-seq counts.

fdata

data.table returned from setup_fdata.

annot

Character vector with ensembldb package name. e.g. 'EnsDb.Hsapiens.v94'. Returned from get_ensdb_package.

Value

ExpressionSet with quants$counts stored in the 'exprs' assay, quants$samples stored in the sample metadata, and fdata stored in the feature data.

Examples


# generate example
y <- matrix(rnbinom(10000, mu = 5, size = 2), ncol = 4)
row.names(y) <- paste0("gene", 1:2500)
quants <- edgeR::DGEList(counts = y)

fdata <- data.table::data.table(gene_name = row.names(y), key = "gene_name")
annot <- dseqr::get_ensdb_package("Homo sapiens", "94")

eset <- construct_eset(quants, fdata, annot)

alexvpickering/rkal documentation built on Nov. 27, 2022, 8:38 p.m.