regenrich_diffExpr {RegEnrich} | R Documentation |
This is the first step of RegEnrich analysis. differential expression analysis by this function needs to be performed on a 'RegenrichSet' object.
regenrich_diffExpr(object, ...) ## S4 method for signature 'RegenrichSet' regenrich_diffExpr(object, ...)
object |
a 'RegenrichSet' object, which is initialized by
|
... |
arguments for differential analysis.
After constructing a 'RegenrichSet' object,
all arguments for RegEnrich analysis have been initialized and
stored in 'paramsIn“ slot. while the arguments for differential analysis
can be re-specified here. |
This function returns a 'RegenrichSet' object with an updated
'resDEA' slot, which is a 'DeaSet' object, and an updated 'paramsIn' slot.
See newDeaSet
function for more details about 'DeaSet' class.
If an argument not in the above list is specified in the regenrich_diffExpr
function, a warning or error will be raised.
Initialization of a 'RegenrichSet' object
RegenrichSet
,and next step
regenrich_network
.
# library(RegEnrich) data("Lyme_GSE63085") data("TFs") data = log2(Lyme_GSE63085$FPKM + 1) colData = Lyme_GSE63085$sampleInfo # Take first 2000 rows for example data1 = data[seq(2000), ] design = model.matrix(~0 + patientID + week, data = colData) # Initializing a 'RegenrichSet' object object = RegenrichSet(expr = data1, colData = colData, method = 'limma', minMeanExpr = 0, design = design, contrast = c(rep(0, ncol(design) - 1), 1), networkConstruction = 'COEN', enrichTest = 'FET') # Using the predifined parameters in the previous step (object = regenrich_diffExpr(object)) # re-specifying parameter 'minMeanExpr' print(slot(object, 'paramsIn')$minMeanExpr) (object = regenrich_diffExpr(object, minMeanExpr = 1)) print(slot(object, 'paramsIn')$minMeanExpr) # Unrecognized argument 'unrecognizedArg' (Error) # object = regenrich_diffExpr(object, minMeanExpr = 1, # unrecognizedArg = 23) # Argument not for differential expression analysis (Warning) # print(slot(object, 'paramsIn')$networkConstruction) # (object = regenrich_diffExpr(object, minMeanExpr = 1, # networkConstruction = 'GRN')) # print(slot(object, 'paramsIn')$networkConstruction) # not changed