Sep 27 2024 03:28 AM
Hi all,
I have a challenge with calculating the Average within a row of cells, based on what's in those cells. I need to find the first 12 cells that are e.g. >=10, and take an average, but ignore cells <10 and move to the next cell if need be.
Any ideas??
Sep 27 2024 03:49 AM
SolutionI offer an Excel 365 solution using BYROW:
=BYROW(
scenarios,
LAMBDA(each_scenario,
LET(
crit, each_scenario >= 10,
filtered, FILTER(each_scenario, crit, 0),
AVERAGE(TAKE(filtered, , 12))
)
)
)
Sep 27 2024 03:55 AM
Sep 27 2024 04:01 AM
Sep 27 2024 04:02 AM
Sep 27 2024 03:49 AM
SolutionI offer an Excel 365 solution using BYROW:
=BYROW(
scenarios,
LAMBDA(each_scenario,
LET(
crit, each_scenario >= 10,
filtered, FILTER(each_scenario, crit, 0),
AVERAGE(TAKE(filtered, , 12))
)
)
)