plotTopLOLAEnrichments {LOLA} | R Documentation

## Given some results (you grab the top ones on your own), this plots a barplot visualizing their odds ratios.

### Description

Given some results (you grab the top ones on your own), this plots a barplot visualizing their odds ratios.

### Usage

    plotTopLOLAEnrichments(data)

### Arguments

`data` | A results table returned from runLOLA()

### Value

Returns a ggplot2 plot object.

### Examples

    dbPath = system.file("extdata", "hg19", package="LOLA")
    regionDB = loadRegionDB(dbLocation=dbPath)
    data("sample_universe", package="LOLA")
    data("sample_input", package="LOLA")

    getRegionSet(regionDB, collections="ucsc_example", filenames="vistaEnhancers.bed")
    getRegionSet(dbPath, collections="ucsc_example", filenames="vistaEnhancers.bed")
    getRegionFile(dbPath, collections="ucsc_example", filenames="vistaEnhancers.bed")

    res = runLOLA(userSets, userUniverse, regionDB, cores=1)
    locResult = res[2,]
    extractEnrichmentOverlaps(locResult, userSets, regionDB)
    writeCombinedEnrichment(locResult, "temp_outfolder")

    userSetsRedefined =	redefineUserSets(userSets, userUniverse)
    resRedefined = runLOLA(userSetsRedefined, userUniverse, regionDB, cores=1)

    g = plotTopLOLAEnrichments(resRedefined)

[Package LOLA version 1.14.0 Index]