path_obj_filter: Finds the limit cutoff when target and sentinal paths are...

path_obj_filterR Documentation

Finds the limit cutoff when target and sentinal paths are given

Description

Using all paths from an igraph path trace this will filter all the paths in the trace by the lim argument. Implementation deploys path_filter() in parallel over the number of cores specified by the cores argument.

Usage

path_obj_filter(path_obj, vertices, lim, path_name, weights, cores = 1)

Arguments

path_obj

pathtrace object from short_paths()

vertices

the vertices vector from find_limit

lim

the filter limit value

path_name

the name of the path for message (target or sentinal)

weights

the gene OMICS scores or score metric by verex to weight paths

cores

the cores to run the path calulation over. default = 1

Value

list of vertex names from paths that path the filter limit

Examples

example_path <- list()
example_path$res <- list(
   c('319', "49", "23", "86", "690", "238"),
   c('422', "899", "37", "240", "970", "28")
)
names(example_path$res[[1]]) <- c(
   "GeneA","GeneZ", "GeneAlpha",
   "GeneB", "GeneX", "GeneOmega"
)
names(example_path$res[[2]]) <- c(
   "Gene1","Gene2", "GeneUno",
   "Gene12", "Gene13", "GeneOcho"
)

sampweights <- c(1.45, 2.45, 0.89, .003, 1.3, 2.1, 0.02, 0, 0, 0.2, 0.6, .70)
names(sampweights) <- c(
   "GeneA","GeneZ", "GeneAlpha",
   "GeneB", "GeneX", "GeneOmega",
   "Gene1","Gene2", "GeneUno",
   "Gene12", "Gene13", "GeneOcho"
)
path_obj_filter(
   path_obj = example_path,
   path_name =  "test",
   vertices = c(0,0,0),
   weights = sampweights,
   lim = 1,
   cores = 2
)

jgockley62/igraphNetworkExpansion documentation built on April 15, 2022, 12:14 a.m.