Description Usage Arguments Value Note Author(s) Examples
Retrieve a node from a graph by name.
1 | cg_graph_get(graph, name)
|
graph |
cg_graph object, graph containing the node to be retrieved. |
name |
character scalar, name of the node to be retrieved. |
cg_node object.
In case multiple nodes share the same name, the last node added to the graph is retrieved.
Ron Triepels
1 2 3 4 5 6 7 8 9 10 11 | # Initialize a computational graph
graph <- cg_graph()
# Add an input
a <- cg_input(name = "a")
# Retrieve input a
b <- cg_graph_get(graph, "a")
# Check equality
identical(a, b)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.