Learn R Programming

EnrichedHeatmap (version 1.2.2)

enriched_score: Enriched scores

Description

Enriched scores

Usage

enriched_score(x1, x2, x3)

Arguments

x1
a vector corresponding to values in upstream windows
x2
a vector corresponding to values in target windows
x3
a vector corresponding to values in downstream windows

Value

  • A numeric value.

Details

The function calculates how the signal is enriched in the targets. The score is the sum of values weighted by the reciprocal of the distance to the targets.

Basically, to be a score function which calculates enriched score, it should accept three arguments which are explained in **Arguments** section and return a single value. Rows are sorted decreasingly by the enriched scores.

Examples

Run this code
enriched_score(c(1, 2, 3), c(1, 2, 1), c(3, 2, 1))
enriched_score(c(3, 2, 1), c(2, 1, 2), c(1, 2, 3))

Run the code above in your browser using DataLab