plot.pathwayMap_CaseCntl: Generate pathway map with patient perturbation data...

View source: R/plot.pathwayMap_CaseCntl.r

plot.pathwayMap_CaseCntlR Documentation

Generate pathway map with patient perturbation data superimposed.

Description

Generate pathway map with patient perturbation data superimposed.

Usage

plot.pathwayMap_CaseCntl(Pathway, groupName, pvalues, out.path, SVG=TRUE)

Arguments

Pathway

- The name of the pathway map you want to plot patient data on.

groupName

- An identifier string associated with the group being compared to a "baseline" condition.

pvalues

- A named vector of metabolites with corresponding p-values (e.g., from a t-test).

out.path

- The directory in which you want to store image files.

SVG

- Save as SVG or PNG? If SVG is TRUE, then an SVG image is saved. If FALSE, a PNG is saved.

Examples

require(CTD)
data(Miller2015)
Miller2015 = Miller2015[,grep("IEM", colnames(Miller2015))]
type = diagnoses$diagnosis
sdd = apply(Miller2015[,which(type=="Argininemia")], 1, sd)
Miller2015 = Miller2015[-which(sdd==0),]
pvals = unlist(apply(Miller2015, 1, function(i) t.test(i[which(type=="Argininemia")], i[which(type=="No biochemical genetic diagnosis")])$p.value))
names(pvals) = rownames(Miller2015)
pwys = pathway.ListMaps_metabolon()
plot.pathwayMap_CaseCntl("allPathways", groupName="Argininemia", pvalues=pvals, out.path=getwd(), SVG=TRUE)

BRL-BCM/CTDext documentation built on May 7, 2022, 5:31 a.m.