regenrich_enrich {RegEnrich} | R Documentation

## Enrichment analysis step

### Description

As the thrid step of RegEnrich analysis, enrichment analysis is followed by differential expression analysis (regenrich_diffExpr), and regulator-target network inference (regenrich_network).

### Usage

    regenrich_enrich(object, ...)

    ## S4 method for signature 'RegenrichSet'
    regenrich_enrich(object, ...)

### Arguments

`object` | a 'RegenrichSet' object, to which `regenrich_diffExpr`, and `regenrich_network`, functions have been already applied.
`...` | arguments for enrichment analysis. After constructing a 'RegenrichSet' object using `RegenrichSet` function, all arguments for RegEnrich analysis have been initialized and stored in 'paramsIn“ slot. The arguments for enrichment analysis can be re-specified here. These arguments include 'enrichTest', 'namedScoresCutoffs', 'minSize', 'maxSize', 'pvalueCutoff','qvalueCutoff', 'regAltName', 'universe', 'minSize', 'maxSize', 'pvalueCutoff', and 'nperm'. See `RegenrichSet` function for more details about these arguments.

### Value

This function returns a 'RegenrichSet' object with an updated 'resEnrich' slots, which is 'Enrich' objects, and an updated 'paramsIn' slot. See `Enrich-class` function for more details about 'Enrich' class.

### See Also

Previous step `regenrich_network`, and next step `regenrich_rankScore`.

### Examples

    # 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')

    # Differential expression analysis
    object = regenrich_diffExpr(object)

    # Network inference using 'COEN' method
    object = regenrich_network(object)

    # Enrichment analysis by Fisher's exact test (FET)
    (object = regenrich_enrich(object))

    # Enrichment analysis by Fisher's exact test (GSEA)
    (object = regenrich_enrich(object, enrichTest = "GSEA"))

[Package RegEnrich version 1.4.0 Index]