BYCOLContainsλ() This is a helper function. It applies a function that we select or create to each column in a 'values' array filtered by a 'labels' array containing specified text
BYCOLContainsλ( ValuesToFilter, ValueLabels, FilterByText, [Function], [IgnoreCase?])
ValuesToFilter
(Required) An array of values to be filtered
ValueLabels
(Required) An array containing the values' labels
FilterByText
(Required) A unique letter, word or phrase to find contained in ValueLabels
Function
(Optional) An Excel function or a LAMBDA function to process a column of values. Default = SUM.
IgnoreCase?
(Optional) A flag to determine if Text's case is important. Default is TRUE.
In this example we are applying ths SUM function to all the values in the depreciation schedule array where the word "CAPEX" is found in the labels array. We then copy the formula down to get totals for Depreciation, Book Value, Revenue from Sale, and Disposal Costs.