Formula to sum of every nth row

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is there a formula out there that will sum every nth row? I have a template
that has the same measure in consecutive rows and rather than selecting the
cells manually would like to enter a formula.

Thanks for the help.
 
=SUMPRODUCT(--(MOD(ROW(B1:B100),n)=m),B1:B100)

where n is the nth row, m is the start point, and should be >0 and <=n-1

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
Say you want to sum every 3rd row and your data starts from A1 thru A42 the
following will sum every 3rd row

=SUM(IF(MOD(ROW(A1:A42),3)=0,A1:A42))
Array entered (ctrl+shift+enter)

Now changing 3 to 4 in the fomula will sum every 4th row

However be careful with the beginning row number where the sum range begins
as this formula would need tweaking to adopt to that
 
Back
Top