View source: R/fct_visNetwork_helpers.R
graphdf_to_visNetwork | R Documentation |
Turns a graph dataframe (from gfpop) into a list that can be read by visNetwork
graphdf_to_visNetwork( graphdf, edgeSep = "_", showNull = TRUE, label_columns = c("type", "penalty"), label_collapse = " | ", edge_ids = c() )
graphdf |
A graph object (in the form of a dataframe) from gfpop Must have the following columns:
|
edgeSep |
A character seperating the nodes in an edge label |
showNull |
(Boolean) hide null edges? |
label_columns |
(character) An array of columns to use to make edge labels |
label_collapse |
the character separating edge columns in this label |
edge_ids |
An array of ids, one for each edge in the graphdf |
a list that can be read by visNetwork
graphdf_to_visNetwork(gfpop::graph(type = "std"), edge_ids = 1:2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.