title: d3 stacked bar chart - start at y0, not yMax
body: <p>I have this stacked bar chart: 
  <a href="http://jsfiddle.net/maneesha/n7eLLnrm/2/" rel="nofollow">http://jsfiddle.net/maneesha/n7eLLnrm/2/</a></p>
  
  <p>The problem is that it looks like the stacking starts at yMax and goes down, not at y0 going up.</p>
  
  <p>This wasn't a problem and wasn't apparent at first when I had the same count (number of people) in each series (year).  Now that some years have more people I realize something is wrong.  Where do I fix this?</p>
  
  <p>Some possibly relevant parts of my code:</p>
  
  <pre><code>yScale = d3.scale.linear()
      .domain([0, yMax])
      .range([height, 0]),
  </code></pre>
  
  <p>//////</p>
  
  <pre><code>rects = groups.selectAll('rect')
      .data(function (d) {
          return d;
          })
      .enter()
      .append('rect')
      .attr('x', function (d) {
          return xScale(d.x);
          })
      .attr('y', function (d) {
          return height - yScale(d.y0);
          })
      .attr('height', function (d) {
          return height - yScale(d.y);
  
          })
      .attr('width', function (d) {
  
          return xScale.rangeBand();
          })
  </code></pre>