ct.upSet: Consolidate shared signals across many contrasts in an UpSet...

View source: R/compareContrasts.R

ct.upSetR Documentation

Consolidate shared signals across many contrasts in an UpSet Plot

Description

This function takes in a named list of 'results' dataframes produced by 'ct.generateResults()' or similar, harmonizes them, and identifies overlaps between them using the logic implemented in 'ct.compareContrasts()'. It then uses the overlaps of these sets to compose an UpSet plot summarizing shared overlaps of the provided contrasts. These overlaps can be specified with some detail via arguments passed to the 'ct.compareContrasts()' function; see documentation for more details.

Note that the UpSet plot is constructed to respect signal directionality, and by default constructs overlaps conditionally, but in a *bidirectional* manner. That is, a signal is considered observed in two (or more) contrasts regardless of the contrast from which the stringent signal is observed, so a signal replicated in three contrasts is interpreted as a target for which the evidence crosses the stringent threshold in one or more of the contrasts and passes the lax contrast in the others.

Note that multiple important parameters are passed directly to 'ct.compareContrasts()' if not specified in the command. Users are advised to study the corresponding manual page to better understand their options regarding contrast thresholding, orientation, etc.

Usage

ct.upSet(dflist, add.stats = TRUE, nperm = 10000, ...)

Arguments

dflist

a named list of (possibly simplified) 'resultsDf's.

add.stats

Logical indicating whether the significance of set overlaps should be included in the visualization.

nperm

Number of permutations for P-value generation. Ignored if 'add.stats' is 'FALSE'.

...

Other named arguments to 'ComplexHeatmap::UpSet()', 'ct.compareContrasts', or 'ct.simpleResult()'.

Value

An UpSet plot on the current device. Silently, a combination matrix appropriate for plotting that plot, containing useful information about the observed intersections.

Author(s)

Russell Bainer

Examples

data('resultsDF')
sets <- ct.upSet(list('first' = resultsDF, 'second' = resultsDF[1:5000,]))

RussBainer/gCrisprTools documentation built on Nov. 5, 2022, 2:35 p.m.