NBAMSeqDataSet: NBAMSeqDataSet constructor

Description Usage Arguments Value Examples

View source: R/AllClasses.R

Description

NBAMSeqDataSet constructor

Usage

1
NBAMSeqDataSet(countData, colData, design, ...)

Arguments

countData

a matrix or data frame contains gene count

colData

a DataFrame or data.frame

design

a mgcv type design. e.g. ~ s(pheno) or ~ s(pheno) + var1 + var2

...

optional arguments passed to SummarizedExperiment

Value

a NBAMSeqDataSet object

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
n = 100  ## n stands for number of genes
m = 20   ## m stands for sample size
countData = matrix(rnbinom(n*m, mu=100, size=1/3), ncol = m)
mode(countData) = "integer"
colnames(countData) = paste0("sample", 1:m)
rownames(countData) = paste0("gene", 1:n)
pheno = runif(m, 20, 80)
colData = data.frame(pheno = pheno)
rownames(colData) = paste0("sample", 1:m)
gsd = NBAMSeqDataSet(countData = countData,
colData = colData, design = ~s(pheno))

reese3928/NBAMSeq documentation built on Oct. 29, 2020, 8:06 a.m.