count_nodes | R Documentation |
From a graph object of class dgr_graph
, get a count of nodes in the graph.
count_nodes(graph)
graph |
A graph object of class |
A numeric vector of single length.
# Create a graph with a # path of nodes and 3 # unconnected nodes graph <- create_graph() %>% add_path(n = 3) %>% add_n_nodes(n = 3) # Get a count of all nodes # in the graph graph %>% count_nodes()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.