How to change the direction of the arrow on targetto sourcefrom sourceup targetin accordance with the documentation, he said, to use Objectthe method .edges( Array | Object | url ). D3plus documentation . The complete code is as follows to learn about the direction of the arrow.
<!doctype html>
<meta charset="utf-8">
<script src="//d3plus.org/js/d3.js"></script>
<script src="//d3plus.org/js/d3plus.js"></script>
<div id="viz"></div>
<script>
var connections = [
{"source": "alpha", "target": "beta"},
{"source": "alpha", "target": "gamma"},
{"source": "alpha", "target": "delta"},
{"source": "alpha", "target": "epsilon"},
{"source": "alpha", "target": "peta"},
{"source": "alpha", "target": "zeta"},
{"source": "alpha", "target": "eta"}
]
var visualization = d3plus.viz()
.container("#viz")
.type("rings")
.edges(connections)
.edges({"direction":{"accepted":["source","target"],"value":"source"}})
.edges({"arrows":true,"color":"#000000"})
.focus("alpha")
.draw()
</script>
Console message.

source
share