Here is an example of curve edge:
library(visNetwork) # v2.1.2
nodes = data.frame(id = letters[1:6],
label = letters[1:6])
edges = data.frame(from = c("a", "a", "a", "a", "b", "d", "d", "e"),
to = c("b", "c", "d", "e", "c", "e", "f", "f"))
edges <- (edges
%>% mutate(
smooth.enabled= TRUE,
smooth.type='dicrete',
roundness=0.8
)
)
visNetwork(
nodes = nodes,
edges = edges
)
Try other options explained here :
And convert it to R visNetwork. For example "smooth": { "type": "cubicBezier" }
becomes smooth.type='cubicBezier'
.