title: dc.js pie chart sum example
body: <p>I have records like this : </p>
  
  <pre><code>{
  {"Pass": "10", "Fail": "20", "Untested": "40"}
  {"Pass": "20", "Fail": "40", "Untested": "50"}
  {"Pass": "30", "Fail": "50", "Untested": "60"}
  ...
  }
  </code></pre>
  
  <p>Obviously, total = pass + fail + untested. I want to sum up each of these values and then finally show a pie chart using dc.js that shows total Pass, total Fail, total Untested. I couldnt find a good example. </p>
  
  <p>In the example below, each record is converted to a binary loss/gain value. Then the pie chart shows the aggregated loss/gain. I need to aggregate at the collection level, not individual record level. How can I do that ? </p>
  
  <p>Any help is much appreciated.</p>
  
  <p>Ref:</p>
  
  <p><a href="http://nickqizhu.github.io/dc.js/" rel="nofollow">http://nickqizhu.github.io/dc.js/</a></p>