Forum Discussion
David-A-S
Mar 12, 2023Copper Contributor
Filter based on minimum value C for each value A
I'm trying to find a way to filter by a value, and then filter and keep only the lowest value. So the order would look like this: It first filters the middle column by the input, but then I'm s...
- Mar 12, 2023
Assuming your chosen input is in A1 and data in C1:E9
=LET( ξ, A1, ζ, C1:E9, ε, LAMBDA(α, β, INDEX(α, , β)), γ, ε(ζ, 2), δ, FILTER(ζ, γ = ξ), κ, ε(δ, 1), λ, ε(δ, 3), FILTER(δ, λ = BYROW(κ, LAMBDA(μ, MIN(IF(κ = μ, λ))))) )
JosWoolley
Mar 12, 2023Iron Contributor
Assuming your chosen input is in A1 and data in C1:E9
=LET(
ξ, A1,
ζ, C1:E9,
ε, LAMBDA(α, β, INDEX(α, , β)),
γ, ε(ζ, 2),
δ, FILTER(ζ, γ = ξ),
κ, ε(δ, 1),
λ, ε(δ, 3),
FILTER(δ, λ = BYROW(κ, LAMBDA(μ, MIN(IF(κ = μ, λ)))))
)