enrichmentMap {PathwaySplice} | R Documentation

## enrichmentMap

### Description

This function draws an enrichment map based on the overlap of gene sets as measured by the Jaccard Coefficient(JC)

### Usage

    enrichmentMap(pathway.res, n = 50, fixed = TRUE, node.label.font = 1,
      similarity.threshold, scaling.factor = 1, output.file.dir = tempdir(),
      label.node.by.index = FALSE, add.numSIGInCat = FALSE, ...)

### Arguments

`pathway.res` | Pathway analysis results, an object returned by `runPathwaySplice`
`n` | The top n most significant gene sets are shown on enrichment map
`fixed` | If set to FALSE, will invoke tkplot (an interactive graphing facility in R) that allows one to draw an interactive enrichment map. Users can then manually adjust the layout of the enrichment map. Note: on OS X system, users need to have XQuartz installed to run this function . tcltk R package is also required, but in most distributions of R tcltk is already included
`node.label.font` | Font size of node label
`similarity.threshold` | Gene sets with Jaccard Coefficient > `similarity.threshold` will be connected on the enrichment map
`scaling.factor` | Scaling factor that users can use to adjust the edge thickness of the network, which is based on value of sqrt(JC coefficient * 5) * scaling.factor
`output.file.dir` | Output files directory, see `Details` section below.
`label.node.by.index` | Options for labeling nodes on network. FALSE indicates to label nodes by gene set names TRUE indicates to label nodes by the index of gene sets
`add.numSIGInCat` | Option for users to decide whether to add number of signficant genes of each gene set to the nodes in enrichment map or not
`...` | Additional parameter

### Details

In the enrichment map,

- the node colors are controlled by gene set p-values, where smaller p-values correspond to dark red color.

- node sizes are controlled by the number of significant genes in gene set.

- thickness of the edges correspond to Jaccard similarity coefficient between two gene sets.

- the numbers after ':' indicates the nubmer of significant genes in the gene set.

The Jaccard similarity coefficient ranges from 0 to 1. JC=0 indicates there are no overlapping genes between two gene sets, JC=1 indicates two gene sets are identical.

The output directory will include the following files:

(1) a network file (in GML format) that can be used as an input for Cytoscape software (2) when label.node.by.index=TRUE, also a gene set information file that includes full names of the gene sets and the gene set indices shown on the network.

### Value

A list with edge and node information used to plot enrichment map

### Author(s)

Aimin created this funciton based on enrichMap function in G Yu's DOSE R package

### Examples

    gene.based.table <- makeGeneTable(featureBasedData)

    res <- runPathwaySplice(gene.based.table,genome='hg19',
                             id='ensGene',test.cats=c('GO:BP'),
                             go.size.limit=c(5,30),method='Wallenius')

    # labeling each node by gene set name
    enmap <- enrichmentMap(res,n=10,similarity.threshold=0.3,
    label.node.by.index = FALSE)

    # labeling each node by gene set index
    enmap <- enrichmentMap(res,n=10,similarity.threshold=0.3,
    label.node.by.index = TRUE)

    ## Not run:
    # illustrates specification of output file directory
    # Enable interactive map and label each node by gene set index
    enmap <- enrichmentMap(res,n=10,fixed=FALSE, similarity.threshold=0.3,
                          label.node.by.index = TRUE, output.file.dir=tempdir())

    enmap <- enrichmentMap(res,n=10,similarity.threshold=0.3,
                          label.node.by.index = FALSE, output.file.dir=tempdir())
    ## End(Not run)

[Package PathwaySplice version 1.8.0 Index]