Hi All. First time posting but I have referenced this forum many times over the years. It has been a tremendous help. So thank you!
I am trying to get a formula that I can sum non-zero values in a range, but only the first 12 (1-12) from the most recent dates, and then the next 12 (13-24). I found something that works for a range across a row, but I can't figure out how to apply that same concept to a range in a column. My data in column A is months from Jan 2018 - August 2021 (A2:A45). Column B is amounts (B2:B45). The amounts in column B will vary...sometimes having nonzero values in certain months and sometimes it will be zero. Really what I am trying to do is get a sum of the most recent 12 months and then the next 12 months. Appreciate any help.
I am trying to get a formula that I can sum non-zero values in a range, but only the first 12 (1-12) from the most recent dates, and then the next 12 (13-24). I found something that works for a range across a row, but I can't figure out how to apply that same concept to a range in a column. My data in column A is months from Jan 2018 - August 2021 (A2:A45). Column B is amounts (B2:B45). The amounts in column B will vary...sometimes having nonzero values in certain months and sometimes it will be zero. Really what I am trying to do is get a sum of the most recent 12 months and then the next 12 months. Appreciate any help.
Period | Amount |
1/1/18 | - |
2/1/18 | - |
3/1/18 | - |
4/1/18 | - |
5/1/18 | - |
6/1/18 | - |
7/1/18 | - |
8/1/18 | - |
9/1/18 | - |
10/1/18 | - |
11/1/18 | - |
12/1/18 | - |
1/1/19 | 14,595 |
2/1/19 | 12,562 |
3/1/19 | 15,809 |
4/1/19 | 14,550 |
5/1/19 | 15,228 |
6/1/19 | 11,812 |
7/1/19 | 16,388 |
8/1/19 | 14,384 |
9/1/19 | 11,733 |
10/1/19 | 14,615 |
11/1/19 | 12,681 |
12/1/19 | 7,676 |
1/1/20 | 15,674 |
2/1/20 | 12,923 |
3/1/20 | 14,011 |
4/1/20 | 14,693 |
5/1/20 | 14,325 |
6/1/20 | 14,273 |
7/1/20 | 13,591 |
8/1/20 | 13,748 |
9/1/20 | 13,591 |
10/1/20 | 8,712 |
11/1/20 | 10,028 |
12/1/20 | 8,537 |
1/1/21 | - |
2/1/21 | - |
3/1/21 | - |
4/1/21 | - |
5/1/21 | - |
6/1/21 | - |
7/1/21 | - |
8/1/21 | - |