get_edge_df_ws {DiagrammeR} | R Documentation |
From a graph object of class
dgr_graph
, get the graph's internal
edge data frame that is filtered by the edge
ID values currently active as a selection.
get_edge_df_ws(graph)
graph |
a graph object of class
|
an edge data frame.
# Create a random graph using the # `add_gnm_graph()` function graph <- create_graph() %>% add_gnm_graph( n = 4, m = 4, set_seed = 23) %>% set_edge_attrs( edge_attr = value, values = c(2.5, 8.2, 4.2, 2.4)) # Select edges with ID values # `1` and `3` graph <- graph %>% select_edges_by_edge_id( edges = c(1, 3)) # Get the edge data frame that's # limited to the rows that correspond # to the edge selection graph %>% get_edge_df_ws()