plot_stats: Plot overlap statistics as a bar graph

Description Usage Arguments Value Examples

Description

Plot overlap statistics as a bar graph

Usage

1
2
3
4
5
6
7
8
plot_stats(
  stats,
  value,
  color,
  val_trans = "identity",
  col_trans = "identity",
  sort_y = FALSE
)

Arguments

stats

value from compute

value

"#gene sets", "# genes", "# matches", "P-value", "Adjusted P-value", "Odds Ratio", "Fold Enrichment" or "Adjusted Fold Enrichment"

color

"#gene sets", "# genes", "# matches", "P-value", "Adjusted P-value", "Odds Ratio", "Fold Enrichment" or "Adjusted Fold Enrichment"

val_trans

optional: value transformation, see trans argument in scale_continuous; default "identity"

col_trans

optional: color transformation, see trans argument in scale_continuous; default "identity"

sort_y

whether to sort annotations by value

Value

ggplot2: bar chart of statistics

Examples

1
2
3
4
5
6
7
8
anno_path <- system.file("extdata", "ex_anno.csv", package = "glacier")
data_path <- system.file("extdata", "ex_data.csv", package = "glacier")
anno <- import_annotations(anno_path, ",", TRUE, c(2, 4), 5)
data <- import_database(data_path, ",", FALSE, c(2, 4), 0)

input <- process_input_text('CYP1A1 0.2 CYP1B1 NQO1 0.3 SODD 9.0')
results <- compute(input, anno, data)
stat <- plot_stats(results$stats, 'Fold Enrichment', 'Adjusted P-value')

lilin-yang/glacier documentation built on Oct. 3, 2020, 8:06 a.m.