I\'m new to d3js and trying to adapt the streamgraph example from here http://bl.ocks.org/mbostock/4060954:
Thanks minikomi! That was super helpful. The other thing I realized was off was that I wasn't parsing the x & y values into numbers and it was reading them as strings and making the points computation go crazy. So when it's iterating through the rows of the CSV file it needs to use parseInt:
data.forEach(function(d) {
d.date = format.parse(d.date);
d.y = parseInt(d.num_visitors);
d.x = parseInt(d.index);
});
Here are my updated files in case anyone wants to use this as an example in the future.
HTML
Streamgraph