title: Get multiple/grouped sums for a vector with values separated by NA's
body: <p>I have an update on my <a href="https://stackoverflow.com/questions/51760574/get-multiple-sums-for-a-vector-including-many-factor-levels-devided-by-nas">previous question</a>:</p>
  
  <pre><code>c(123, 4525, 4365, 234, 674, NA, NA, NA, NA, NA, NA, NA, 
    24, 347, 457, 3246, 234, 5, 346, NA, NA, NA, NA, NA, NA) # [... and so on]
  </code></pre>
  
  <p>Is there any way to get me the sums for each of my pack of values separated by my NA's? Both the values and the NA's separate in their length over the vector and that's where I see the problem…</p>
  
  <p>Ronak Shah's answer was very helpful but there remains a problem:
  I have some packs of values, which equal 0 in their sum.
  But this is an important information for me!<br>
  So if I use <code>new[new != 0]</code> I cut them off and I have no information on which sums belong to which pack of values in the end.</p>