Average Last 5 Numbers in Column, Excluding "#N/A"

Excel Pooh

New Member
Joined
Jul 20, 2021
Messages
7
Office Version
  1. 365
Platform
  1. Windows
Good morning, I am stumped on this as I can only seem to get one half or the other.

I have a column (F) filled with INDEX/MATCH formulas that return simple numbers. The range is from F3-F20, however, as these numbers are representative of a period of time, they are not always populated with numbers, some still have "#N/A" as we don't know the numerical answer yet.

I am trying to get the average of the last 5 REAL numbers in this selection (F3:F20), but what cells contain the last 5 will be ever-changing as the sheet updates with time. Right now, I have real numbers in F3:F9, and "#N/A" in F10:F20. I would like the average to auto-update to only show the average of the last 5 numbers, even as F10:F20 are populated over time, but until then, they need to be ignored..

Please let me know if I can explain better, I appreciate the help, this has really sent me through the ringer.
 

Excel Facts

Format cells as time
Select range and press Ctrl+Shift+2 to format cells as time. (Shift 2 is the @ sign).
How about this?

Excel Formula:
=AVERAGE(CHOOSEROWS(FILTER(F3:F20,NOT(ISNA(F3:F20))),SEQUENCE(5,,-5,1)))
 
Upvote 0
Thanks everybody, I really appreciate you taking the time to help me. I was stuck in between trying AGGREGATE, not knowing where to fit in the ISNA, and a whole lot of other unsuccessful messy attempts. Have a great Thursday!
 
Upvote 0
Thanks everybody, I really appreciate you taking the time to help me. I was stuck in between trying AGGREGATE, not knowing where to fit in the ISNA, and a whole lot of other unsuccessful messy attempts. Have a great Thursday!
Glad we could help, and thanks for the feedback 👍
 
Upvote 0

Forum statistics

Threads
1,224,813
Messages
6,181,107
Members
453,021
Latest member
Justyna P

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