all_spaths_list: info of all simple paths

Description Usage Arguments Details Value Author(s) Examples

Description

simple paths info: list, nodes and edges

Usage

1
2
3
4
5
all_spaths_list(obj, from, to, mc.cores)
all_spaths_nodes(obj, from, to, mc.cores)
all_spaths_nodes(obj)
all_spaths_edges(obj, from, to, mc.cores)
all_spaths_edges(obj)

Arguments

object

xgraph object or list returned by all_spaths_list

from

character vector of length 1, name of start node

to

character vector of length 1, name of end node

mc.cores

refer to mclapply

n.max

numeric, max number of nodes allowed in the graph. Don't set big number (default 1000) since simple path searching for big network is very very time-consuming.

Details

Wrapers for igraph::all_simple_paths. Parallel computing may be evoked if source or target number is more than one. In these series of functions, all_spaths_list is the basic function; all_spaths_nodes and all_spaths_edges extract infos from the results of all_spaths_list implicitly or explicitly.

Value

character list or vector

Author(s)

ZG Zhao

Examples

1
2
3
4
5
6
7
8
9
library(syzMetab)
d.path <- file.path(path.package("syzMetab"), "KEGG")
gg <- make_mgraph("ko00010", d.path)
vv <- vnames(gg)
(splist <- all_spaths_list(gg, vv[1], vv[6]))
all_spaths_nodes(splist)
all_spaths_nodes(gg, vv[1], vv[6])
all_spaths_edges(splist)
all_spaths_edges(gg, vv[1], vv[6])

zgzhao/gmetab documentation built on Dec. 23, 2021, 9:17 p.m.