pipe_get_graph | R Documentation |
Get the pipeline as a graph with nodes and edges.
pipe_get_graph(pip, groups = NULL)
pip |
|
groups |
|
list with two data frames, one for nodes and one for edges
ready to be used with the visNetwork::visNetwork()
function of the
visNetwork package.
p <- pipe_new("pipe", data = 1:2)
pipe_add(p, "add1", \(data = ~data, x = 1) x + data)
pipe_add(p, "add2", \(x = 1, y = ~add1) x + y)
pipe_add(p, "mult1", \(x = ~add1, y = ~add2) x * y)
graph <- pipe_get_graph(p)
graph
if (require("visNetwork", quietly = TRUE)) {
do.call(visNetwork, args = graph)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.