Skip to contents

[Experimental] Given a list of target gene sets, this function will test for each of the individual target gene sets the hypergeometric enrichment against the specified gene sets.

Usage

rs_hypergeom_test_list(
  target_genes_list,
  gene_sets,
  gene_universe,
  min_overlap,
  fdr_threshold
)

Arguments

target_genes_list

A list of character vectors, each representing a target gene set.

gene_sets

A list of strings that represent the gene sets to test against.

gene_universe

A character vector representing the gene universe from which the target genes and gene sets are sampled from.

min_overlap

Optional integer. Shall a filter be applied on the minimum of overlapping genes.

fdr_threshold

Optional float. Shall a filter be applied for the maximum tolerated FDR.

Value

A list containing (results of all target sets concatenated, only for the tests passing the filters):

  • pvals - The p-values from the hypergeometric test.

  • fdr - The FDRs for each target set calculated across all gene sets.

  • odds_ratios - The calculated odds ratios

  • hits - The size of the overlap between the target gene set and individual gene sets.

  • gene_set_lengths - The length of the gene sets.

  • to_keep - 1-based indices (into gene_sets) of the tests that passed.

  • tests_passed - How many tests passed the filter criteria for that target set.