Description Usage Arguments Details Value Examples
Add edge arrows to a directed graph. Due to complexities of writing custom renderers in webGL, we are stuck with one arrow:edge size ratio. In other words, you can only affect the edge arrow size by making the edges bigger.
1 | addEdgeArrows(sigmaObj)
|
sigmaObj |
A 'sigmaNet' object - created using the 'sigmaFromIgraph' function |
This is only applicable for directed graphs - if you run this on an undirected graph, you'll get an error.
A 'sigmaNet' object with added edge arrows. This object can be called directly to create a visualization, or modified by additional functions.
1 2 3 4 5 6 7 8 9 10 | library(igraph)
library(sigmaNet)
library(magrittr)
g <- graph.formula(A-+B,B-+C,A-+C)
layout <- matrix(c(2,1, 1,0, 3,0),byrow=TRUE,nrow=3)
sig <- sigmaFromIgraph(g, layout = layout)
sig %>%
addEdgeSize(oneSize = 6) %>%
addEdgeArrows()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.