parse_vpath: Parser for G* nodes paths.

Description Usage Arguments Value See Also Examples

Description

Translates a sequence of nodes from a G* graph, generated with any of the available transformations, to a sequence of nodes in terms of the original G.

Usage

1
parse_vpath(vpath)

Arguments

vpath

A vector of character type, representing a path as a sequence of nodes. The nodes are supposed to belong to an original graph G, but be written in terms of G*.

Value

A new vector of character type, representing the same path as vpath but with the nodes names translated to the original graph G's names.

See Also

Other Parsers: direct_graph, get_all_nodes

Examples

1
2
3
4
5
6
# Obtain the vpath from any way, an algorithm or random walk.
# Call the parsing function
translated_vpath <- parse_vpath( c("s|u", "s|u|v", "u|v|y", "t") )

# Print the result
translated_vpath

rsppfp documentation built on May 1, 2019, 10:27 p.m.