delavnog delavnog - 1 year ago 144
Javascript Question

How to edit a node graph?


it is possible to visualize node graphs, like this example

enter image description here

Now I would like to let the user interact with the graph. It must be possible to:

  • create/delete nodes and edges

  • attach data to a node/edge, by clicking on it.

  • push the data to the server, so that it can be made persistent

Is it possible to do that with
? Is there any other tool which offers this kind of functionality?

Answer Source

Sure, all of these things are relatively easy to do with d3. You can see lots of different examples of force directed graphs at Here are a couple that you might find useful:

Adding nodes and edges to a graph:

Loading data from an XML file to create a layout

Listening for mouse over

From personal experience I would say that d3 would be the best tool for doing this sort of thing. I'd suggest playing around with it a bit and then asking more specific questions when you have them.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download