msea: Performs a preranked metabolite set enrichment analysis...

Description Usage Arguments Value Author(s) References Examples

View source: R/msea.R

Description

This function performs a MSEA based on the adaptive multilevel splitting Monte Carlo approach.

Usage

1
2
3
4
5
6
msea(
  metaboliteRanks,
  subOntology = "food",
  pvalCutoff = 0.01,
  fobi = fobitools::fobi
)

Arguments

metaboliteRanks

A named vector of FOBI metabolite identifiers with their metabolite-level stats.

subOntology

A character string specifying one of the two FOBI sub-ontologies: "food", or "biomarker".

pvalCutoff

A numeric value indicating a p-value cutoff for raw p-values generated by MSEA.

fobi

FOBI table obtained with 'parse_fobi()'. If this value is set to NULL, the last version of FOBI will be downloaded from GitHub.

Value

A tibble with MSEA results.

Author(s)

Pol Castellano-Escuder

References

G. Korotkevich, V. Sukhov, A. Sergushichev. Fast gene set enrichment analysis. bioRxiv (2019), doi:10.1101/060012

Pol Castellano-Escuder, Raúl González-Domínguez, David S Wishart, Cristina Andrés-Lacueva, Alex Sánchez-Pla, FOBI: an ontology to represent food intake data and associate it with metabolomic data, Database, Volume 2020, 2020, baaa033, https://doi.org/10.1093/databa/baaa033.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
metabolites <- c(fobitools::idmap$FOBI[1:49], fobitools::idmap$FOBI[70:80])
random_pvals <- c(runif(n = length(metabolites)*0.3, min = 0.001, max = 0.05), runif(n = length(metabolites)*0.7, min = 0.05, max = 0.99))
names(random_pvals) <- metabolites
metaboliteRanks <- random_pvals[order(random_pvals)]

# Food enrichment analysis
fobitools::msea(metaboliteRanks = metaboliteRanks, 
                pvalCutoff = 1)

# Chemical class enrichment analysis
fobitools::msea(metaboliteRanks = metaboliteRanks, 
                subOntology = "biomarker", 
                pvalCutoff = 1)

pcastellanoescuder/FOBIEnrichR documentation built on Jan. 15, 2022, 8:03 a.m.