Average Last 10 Values in Dynamic Range

rob51852

Board Regular
Joined
Jun 27, 2016
Messages
190
Office Version
  1. 2016
Platform
  1. Windows
Hello

Can anyone help me with a formula to average the last 10 values in a dynamic range in column AA? I can do the average in a static range but do not know how to change it to work with a dynamic range.

Thank you
 

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney
How about something like this?


Excel 2010
AAABAC
1Value
216.5
32
43
54
65
76
87
98
109
1110
1211
Sheet2
Cell Formulas
RangeFormula
AC2=AVERAGE(OFFSET(AA1,COUNTA(AA:AA)-10,0,10))
 
Upvote 0
With some control:

=AVERAGE(OFFSET(INDEX(AA:AA,MATCH(9.99999999999999E+307,AA:AA)),0,0,-MIN(10,COUNT(AA:AA))))
 
Upvote 0
With greater flexibility to avoid blank cells in the dynamic range:



AC
26.5

<tbody>
</tbody>
Sheet1

Array Formulas
CellFormula
AC2{=AVERAGE(INDEX(AA:AA,LARGE(IF(ISNUMBER(AA:AA),ROW(AA:AA)-ROW(AA1)+1),10)):INDEX(AA:AA,MATCH(9.99E+307,AA:AA)))}

<tbody>
</tbody>
Entered with Ctrl+Shift+Enter. If entered correctly, Excel will surround with curly braces {}.
Note: Do not try and enter the {} manually yourself

<tbody>
</tbody>
 
Last edited:
Upvote 0

Forum statistics

Threads
1,214,606
Messages
6,120,497
Members
448,967
Latest member
visheshkotha

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top