View source: R/network_analysis.R
make_res_from_graph | R Documentation |
Use a graph made from make_graph_from_veda_df() to create a sankey diagram linking processes with commodities shown as flows.
make_res_from_graph( g, edge_labels = commodity_description, sankey_width = NULL, sankey_height = NULL, font_size = 10 )
g |
igraph representation of network with processes as nodes and commodities as edges |
edge_labels |
Edge attribute used for labelling edges. |
sankey_width |
Width (in pixels) of sankey. |
sankey_height |
Height (in pixels) of sankey. |
font_size |
Numeric. Font size for RES labels. |
NetworkD3 Sankey object
data(demos_001_sector) demos_001_sector %>% filter(period == 2006) %>% make_graph_from_veda_df() %>% make_res_from_graph( edge_labels = commodity_description, font_size = 11) data(demos_007_vdt) demos_007_vdt %>% filter(region == "reg1") %>% make_graph_from_veda_df(input_data_type = "vdt")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.