pam2path: returns all paths between two nodes

Description Usage Arguments Details Value Examples

View source: R/f0.g4n1.code.r

Description

(ba) From the parentship matrix computes recursively all paths between two nodes.

Usage

1
pam2path(pam, d, a)

Arguments

pam

pam object

d

departure node (internal number)

a

arrival node (internal number)

Details

The basic idea is quite simple. All paths between d (departure) and a (arrival) are the paths between every children of d and a, so a recursive procedure can be used.

Value

a list of vectors describing all possible paths going from d to a. The list is sorted according to the length of the path.

Examples

1
2
 g4n3k("RESET"); # needed only for R checking, to be forgotten
 pam2path(g4n.pam1, 1, 5);

g4n documentation built on May 2, 2019, 5:47 p.m.

Related to pam2path in g4n...