Learn R Programming

SHIP (version 1.0.2)

check.path: Check if two genes belong to any common KEGG pathway.

Description

Takes as arguments two vectors of IDs and test whether they have a common ID.

Usage

check.path(p1, p2)

Arguments

p1
Vector of pathways that gene 1 belongs to.
p2
Vector of pathways that gene 2 belongs to.

Value

Return 0 if the two genes don't belong to a common pathway, return 1 otherwise. This is an internal function used by the function target.help.

See Also

target.help

Examples

Run this code
g1 <- c("path1","path2","path3","path4")
g2 <- c("path5","path6","path3","path11")
g3 <- c("path10","path5","path12","path13")
check.path(g1,g2) # 1
check.path(g1,g3) # 0

Run the code above in your browser using DataLab