Index, Match, Large based on two Criteria

JustBL

New Member
Joined
Nov 6, 2024
Messages
2
Office Version
  1. 365
Platform
  1. Windows
I need help indexing team names based on two criteria's
Testing Points For.xlsm
ABCDEFGHIJKLMNOPQRST
1ShotsPoints Win / Loss
2ForDifferenceTeamPointsDifferenceAgainstTeamPointsDifferenceAgainst
3VSTeam 173 8Team 183 Team 581 
4Team 24 34Team 24 3Team 481 
5VSTeam 35 14Team 34 1Team 183 
6Team 461 8Team 481 Team 64 1
7VSTeam 571 8Team 581 Team 34 1
8Team 66 14Team 64 1Team 24 3
9
10
11All ranges F3:H8,J3:M8,O3:R8 are dynamically adjusted based on the input of Range B3:B8 & D3:D8. Currently the range O3:R8 is Index & Match based on the large value from Range K3:K6. I need the Range O3:O8 to populate based on the Largest Value in Range Points(K3:K8) and the coresponding value from the Diffence Range(L3:L8). I require the index match large formula to look up both criterias with the highest points and highest Difference value
12
13
14
15
16
17
Sheet1
Cell Formulas
RangeFormula
F3,F5,F7F3=IF(D3>D4,SUM(D3-D4),IF(D4>D3,-1000,-1000))
G3,G5,G7G3=IF(D3>D4,-1000,IF(D4>D3,SUM(D4-D3),-1000))
H3,H5,H7H3=IF(OR(D3=-1000,D4=-1000),-1000,IF(D3>D4,8,IF(D4>D3,4,IF(D3=D4,2,-1000))))
F4,F6,F8F4=IF(D4>D3,SUM(D4-D3),IF(D3>D4,-1000,-1000))
G4,G6,G8G4=IF(D4>D3,-1000,IF(D3>D4,SUM(D3-D4),-1000))
H4,H6,H8H4=IF(OR(D3=-1000,D4=-1000),-1000,IF(D4>D3,8,IF(D3>D4,4,IF(D3=D4,2,-1000))))
J3:J8J3=IF(B3="","",B3)
K3:K8K3=IF(J3="","",VLOOKUP(J3,$B$3:$H$8,7,0))
L3:L8L3=VLOOKUP(J3,$B$3:$H$8,5,0)
M3:M8M3=VLOOKUP(J3,$B$3:$H$8,6,0)
O3:O8O3=INDEX($J$3:$J$8,MATCH(LARGE($K$3:$K$8+ROW($K$3:$K$8)/10^10,ROWS($O$3:O3)),$K$3:$K$8+ROW($K$3:$K$8)/10^10,0))
P3:P8P3=VLOOKUP(O3,$J$3:$M$8,2,0)
Q3:Q8Q3=VLOOKUP(O3,$J$3:$M$8,3,0)
R3:R8R3=VLOOKUP(O3,$J$3:$M$8,4,0)
Cells with Conditional Formatting
CellConditionCell FormatStop If True
O3:R8Cell Value=-1000textNO
O3:R7Expression=$P3=-1000textNO
O8:R8Expression=$P8=-1000textNO
J3:M8Cell Value=-1000textNO
D3:H8Cell Value=-1000textNO
 

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.
Hi & welcome to MrExcel.
Clear all formulae from O3:R8 & in O3 only put
Excel Formula:
=SORT(J4:M9,{2,3},-1)
Alternatively you could use
Excel Formula:
=SORT(CHOOSECOLS(B3:H8,1,7,5,6),{2,3},-1)
 
Upvote 0
Hi & welcome to MrExcel.
Clear all formulae from O3:R8 & in O3 only put
Excel Formula:
=SORT(J4:M9,{2,3},-1)
Alternatively you could use
Excel Formula:
=SORT(CHOOSECOLS(B3:H8,1,7,5,6),{2,3},-1)
Thank You, second option works perfectly.
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,223,577
Messages
6,173,162
Members
452,503
Latest member
AM74

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top