Re:Glance, a visualizer for Haskell code
by _Robbie on Wednesday January 11, 2017 @06:09PM
(#13378327)
Rotating nodes is an easy way to reduce line crossings. Here's a comparison [0].
However, it does seem that vertical and angled text is harder to read than horizontal text, so there is room to improve here.
[0] https://gist.github.com/rgleichman/f812150151b549ca9f634832c...
GraphViz's "dot" algorithm (i.e., Sugiyama-style graph drawing algorithm) [2] should give a fairly compact representation that is organized into layers, and avoids crossing edges in at least simple cases, but rotating the nodes would again "spread out" the layout by forcing increasing height of each layer.
Under "Possible solutions" you mention "create a better graph layout algorithm" - that sounds quite ambitious, wouldn't this be a PhD-thesis-level research task in itself?
The only graph drawing library I'm aware of that might be competitive with GraphViz's algorithms is MSAGL [3] but that's a .NET library.
[1] https://github.com/rgleichman/glance/issues/1
[2] https://en.wikipedia.org/wiki/Layered_graph_drawing
[3] https://www.microsoft.com/en-us/research/project/microsoft-a...