build.consistent.graph: Build Consistent Graph

Description Usage Arguments Details Value Examples

View source: R/graph.utility.R

Description

build a graph in which all nodes are reachable from root.

Usage

1
build.consistent.graph(g = g, root = "00")

Arguments

g

an object of class graphNEL.

root

name of the class that is on the top-level of the hierarchy (def. root="00").

Details

all nodes not accessible from the root (if any) are removed from the graph and printed on stdout.

Value

a graph (as an object of class graphNEL) in which all nodes are accessible from root.

Examples

1
2
3
4
5
data(graph);
root <- root.node(g);
G <- graph::addNode(c("X","Y","Z"), g);
G <- graph::addEdge(c("X","Y","Z"), c("HP:0011844","HP:0009810","HP:0012385"), G);
G <- build.consistent.graph(G, root=root);

gecko515/HEMDAG documentation built on Oct. 18, 2019, 6:34 a.m.