Home > Software design >  Excel formula to calculate MIN in table filtered
Excel formula to calculate MIN in table filtered

Time:01-29

I have a Table that can be filtered by 1 column values, and want to create a cell that calculates the MIN when filter is applied.

Nº cell A B
2 car 2
3 Moto 30
4 Moto 20
5 car 30
6 Moto 4
7 car 10

So I can calcualte min with =MIN(B2:B7) , but I want to create a cell to calculate the min in both cases:

Filtering "car" : B will show cells 2,5 and 7 so MIN= 2

Filtering "moto": B will show cells 3,4,6 so MIN=4

CodePudding user response:

Solved with @Axel Ritcher comment

=SUBTOTAL(105;B2:B7)

CodePudding user response:

Well, just to show the use of minifs():

enter image description here

=MINIFS(B2:B7,A2:A7,D2)
  • Related