Reading JSON file for force.start()

486 views
Skip to first unread message

Chloe Shiau

unread,
Nov 25, 2015, 1:54:06 PM11/25/15
to d3-js
Hi All, I pulled in a JSON file and am getting this error for D3's force function

Code:

  force
      .nodes(graph.nodes)
      .links(graph.links)
      .start();

Error on line ".start()": 

Uncaught TypeError: Cannot read property 'weight' of undefined (@ d3.v3.min.js:4)



matthew lange

unread,
Nov 30, 2015, 7:05:14 PM11/30/15
to d3...@googlegroups.com
It looks like this has been asked on StackOverflow many times (Google search d3 force weight error)
e.g.

--
You received this message because you are subscribed to the Google Groups "d3-js" group.
To unsubscribe from this group and stop receiving emails from it, send an email to d3-js+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages