Learn R Programming

edge (version 2.4.2)

qvalueObj: Access/set qvalue slot

Description

These generic functions access and set the qvalue object in the deSet object.

Usage

qvalueObj(object)

qvalueObj(object) <- value

## S3 method for class 'deSet': qvalueObj(object)

## S3 method for class 'deSet': qvalueObj(object) <- value

Arguments

object
S4 object: deSet
value
S3 object: qvalue

Value

  • qvalueObj returns a qvalue object.

See Also

lrt, odp and deSet

Examples

Run this code
# import data
library(splines)
library(qvalue)
data(kidney)
age <- kidney$age
sex <- kidney$sex
kidexpr <- kidney$kidexpr
cov <- data.frame(sex = sex, age = age)

# create models
null_model <- ~sex
full_model <- ~sex + ns(age, df = 4)

# create deSet object from data
de_obj <- build_models(data = kidexpr, cov = cov, null.model = null_model,
full.model = full_model)

# run the odp method
de_odp <- odp(de_obj, bs.its = 20)

# extract out significance results
qval_obj <- qvalueObj(de_odp)

# run qvalue and assign it to deSet slot
pvals <- qval_obj$pvalues
qval_new <- qvalue(pvals, pfdr = TRUE, fdr.level = 0.1)
qvalueObj(de_odp) <- qval_new

Run the code above in your browser using DataLab