title: How to create a percentage that is the sum of a quantity under many conditions
body: <p>I didn't know how to search for this question, apologies in advance if it was already answered.</p>
  
  <p>I have a table with some batches, and each batch belongs to a product, and for each batch, whether the quality test failed or passed, and the quantity of products in this batch.</p>
  
  <p>What I want to do is to create a percentage of the failed batches, but I can't seem to know how to do it.</p>
  
  <p>I already have a matrix that displays for each product, the total of failed and passed quantities along with their total, so all I want to do is have another column next to it that displays the percentage of failed products.</p>