title: d3js g element x is NaN
body: <p>I'm using d3js, this is my code: </p>
  
  <pre><code>function update () {
      var _node = vis.select("#nodeG").selectAll("g.node")
                     .data(nodes, function (d) {
                         return d.id; 
                     });
  
      var n = _node.enter().append("g")
                   .attr("class", "node")
                   .call(force.drag);
  
      n.append("svg:a").attr("xlink:href", function (d) { return "/user/" + d.id; })
              .append("svg:circle")
              .attr("class", "nodeCircle")
              .attr("cx", function () {
                  i++
                  return parseFloat((i * 50) + 25);
              })
              .attr("cy", HEIGHT / 2)
              .attr("r", function (d) { return d.r; });
  
      force.on("tick", function () {
      _node.attr("transform", function (d) {
           return "translate(" + d.x + "," + d.y + ")";
       });
  });
  </code></pre>
  
  <p>The problem is that <code>d.x</code> and <code>d.y</code> gives me a <code>NaN</code>. I have no idea why. Can someone help me please.</p>