views:

128

answers:

5

I have graphs (nodes/arcs) that I want to display to the user. I need to be able to capture the event of a user clicking on a node.

Something like Google Charts API's Simple Org Chart would be great, but it looks like it only supports trees.

I would like to use JavaScript.

What other service/toolkit can I use? Or should I hack something ugly together using Google Charts?

UPDATE: I am also interested in learning SilverLight. Is there a good graph visualization tool for it?

Possibly useful: http://stackoverflow.com/questions/7034/graph-visualization-code-in-javascript

Also, most of these graphs will be small (20 nodes at most). (The user will specify a node he wants to view, and the code will render the neighborhood.) However, what if the user could traverse the entire graph (1000+ nodes) at once, like Google Maps? I'm not even sure where I would get started doing that.

+5  A: 

Raphaeljs is an interesting charting library:

... Raphaël uses the SVG W3C Recommendation and VML as a base for creating graphics. This means every graphical object you create is also a DOM object, so you can attach JavaScript event handlers or modify them later.

The MYYN
A: 

Check Google Chart Tools again, it doesn't only support trees. http://code.google.com/apis/charttools/

gok
Can you show me what Google Chart visualization I could use to do this?
Rosarch
A: 

There are several JavaScript Chart soluitions: - http://www.splashnology.com/blog/javascripts/290.html - http://www.reynoldsftw.com/2009/03/javascript-chart-alternatives/

IMO Flot is pretty cool: See this interactive sample how you can interact with a datapoint http://people.iola.dk/olau/flot/examples/interacting.html.

bertelmonster2k
+1  A: 

Graphviz is a very commonly used system for generating directed/undirected graphs. It's a standalone app that you supply with a simple format input file in order to generate the graph image. There are a couple of more web-oriented offshoots called webdot and canviz that may get you closer to what you need.

the_mandrill
A: 

Protovis is another good option.

Jay Askren