Forum Discussion
Use SUMIFS on Multiple Columns using BYCOL?
- May 20, 2022
As it happens, I have some LAMBDA functions which will be of use to you here.
Please create named functions for these two:
RECURSIVEFILTER:
https://gist.github.com/ncalm/f1c7b5bd8fe86528da88798b545053c8
GROUPAGGREGATE:
https://gist.github.com/ncalm/29c473a940997c3b112bf06e7e71cf15
As you can see, you define a control array which contains either the word group, or the name of an aggregate function you want to use, then you select the table you want to apply the lambda to, select the control array, and it produces the output.
Apart from the "group" fields (of which the function supported nested row headers), these aggregates are supported at time of writing:
{"textjoin",
"sum",
"min",
"max",
"counta",
"count",
"average"}
If you'd like to get a better understanding of how it works, you are welcome to read this blog post which explains it in detail:
https://www.flexyourdata.com/blog/quickly-create-summary-tables-in-excel-with-just-one-formula/