data.getMSEA_Metabolon: Metabolite set enrichment analysis (MSEA) using pathway...

Description Usage Arguments Examples

Description

A function that returns the pathway enrichment score for all perturbed metabolites in a patient's full metabolomic profile.

A function that returns the pathway enrichment score for all perturbed metabolites in a patient's full metabolomic profile.

Usage

1
2
3
4
5
data.getMSEA_Metabolon(met.profile, threshold = 3, type = "zscore",
  gene.profile = NULL)

data.getMSEA_Metabolon(met.profile, threshold = 3, type = "zscore",
  gene.profile = NULL)

Arguments

met.profile

- A character vector of a patient's metabolomic profile, including KEGG IDs and the associated z-score or p-value describing the level of the metabolite compared to controls.

threshold

- A cutoff to select metabolites with a zscore > threshold or < -1*threshold.

type

- Either "p-value" or "z-score".

gene.profile

- Default set to NULL, meaning the default enrichment analysis only considers metabolites. However, if you have gene data, too, set this parameter to a character vector of the gene names with found variants in the patient's record. Gene IDs must be converted to Entrez Identifiers.

p.corr

- A vector of correlations representing the correlation of the metabolite level with a disease phenotype. The names of the vector are the metabolite names.

met.profile

- A character vector of a patient's metabolomic profile, including KEGG IDs and the associated z-score or p-value describing the level of the metabolite compared to controls.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
data(Miller2015_Heparin)
diagnoses = gsub("[[:digit:]]", "", colnames(Miller2015_Heparin))
diag.ind = diagnoses
diag.ind[which(diag.ind!="Argininemia")] = 0
diag.ind[which(diag.ind=="Argininemia")] = 1
diag.ind = as.numeric(diag.ind)
profile.ind = which(diagnoses=="Argininemia")[1]
met.profile = Miller2015_Heparin[,profile.ind]
names(met.profile) = rownames(Miller2015_Heparin)

population = names(met.profile)
paths.hsa = list.dirs(path="../inst/extdata", full.names = FALSE)
paths.hsa = paths.hsa[-which(paths.hsa %in% c("", "RData", "allPathways"))]
sink("MetaboliteSetDatabases/Miller2015.gmt")
for (p in 1:length(paths.hsa)) {
  load(sprintf("../inst/extdata/RData/%s.RData", paths.hsa[p]))
  pathway.compounds = V(ig)$label[which(V(ig)$shape=="circle")]
  pathCompIDs = unique(tolower(pathway.compounds[which(pathway.compounds %in% population)]))
  print(sprintf("%s         %s", paths.hsa[p], paste(pathCompIDs, collapse="    ")), quote=FALSE)
}
sink()
print("test")
abs_filename_dataset = "Datasets/Miller2015.gct"
abs_filename_classes = "Datasets/Miller2015_arg.cls"
pathway.data = data.getMSEA_Metabolon(met.profile, diag.ind, Miller2015_Heparin)

pathway.data = data.getMSEA_Metabolon(met.profile, threhold=3, "z-score", NULL)

NCBI-Hackathons/Metabolomics-Data-Portal documentation built on May 31, 2019, 9:59 a.m.