title: How do I split values into equal ranges in one column and sum the associated value of another column in R?
body: <p>I have a dataframe named <code>Cust_Amount</code> which is as follows:</p>
  
  <pre><code>Age    Amount_Spent
  25       20
  43       15
  32       27
  37       10
  45       17
  29       10
  </code></pre>
  
  <p>I want to break it down into equal sized age groups and sum the amount spent for each age groups as given below:</p>
  
  <pre><code>Age_Group  Total_Amount
   20-30     30
   30-40     37
   40-50     32
  </code></pre>