Force-directed-graph customization questions

13 views
Skip to first unread message

Matan Safriel

unread,
Apr 29, 2015, 6:50:37 PM4/29/15
to d3...@googlegroups.com
Hi, 

It's been a while since I used d3, and I never used the force directed layout.
I would like to accomplish a force directed layout, where I can also:
  1. separately set the color of each line
  2. separately set the thickness of each line
  3. make each line narrower towards its middle and thicker towards the edges it connects, rather than a monotonous line. More like a chord than a line.
  4. have text show up inside each node (assume each node is a circle/ellipse or rectangle)
  5. some compassion from the force layout algorithm in terms of minimizing text cut-offs and overlaps (I assume this just isn't part of the layout algorithm as I see here...)
  6. have each node also respond to hover/click events (not sure how click is controlled by the code in this example and whether hover events can also be detected)
I figure I may have the layout use transparent lines or no lines at all, and take care of some of these wizardries in my own code. Would that exclude the animations? anyway that would only solve for the line styling (1-3).
I'd be very happy for your feedback before diving in.

Many thanks!
Matan
Reply all
Reply to author
Forward
0 new messages