Team Position (1, 2, 3 etc) based on multiple criteria

StaceyVECL

New Member
Joined
Apr 13, 2022
Messages
32
Office Version
  1. 365
Platform
  1. Windows
Hi All,

I am running a basketball league and need to make the results and standings easier to see with minimal input.

I have all the results as they should be using the NBA format. However, I want the spreadsheet to tell me the position of the team automatically based on win %, conference wins and division wins. At the moment I am sorting the data and manually entering the position.

The result needs to show as 1, 2, 3, 4 etc, is there a way to do this?

Thanks, Stacey
 

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.
This question is very much data dependent. So I think we will need to see what your data looks like, how it is structured, and what you want your expected results to look like.

MrExcel has a tool called “XL2BB” that lets you post samples of your data that will allow us to copy/paste it to our Excel spreadsheets, so we can work with the same copy of data that you are. Instructions on using this tool can be found here: XL2BB Add-in

Note that there is also a "Test Here” forum on this board. This is a place where you can test using this tool (or any other posting techniques that you want to test) before trying to use those tools in your actual posts.
 
Upvote 0
Thanks, Joe. The add-in isn't working. What I have so far is the below.

I am manually entering the "standing" but I need a formula to return the standing based on win%. If the win % is the same (see 5 + 6 below) then it uses conf. wins, if conf. wins is the same (see 5 + 6 below) it then uses div. wins to determine the higher position.

StandingTeamDivisionConferenceTotal WinsTotal LosesWin%Conf. WinsConf. LosesDiv. WinsDiv. Loses
1 EastBoston CelticsAtlanticEastern6217
0.785​
3910151
2 EastMilwaukee BucksCentralEastern4931
0.613​
3417107
3 EastNew York KnicksAtlanticEastern4732
0.595​
3217105
4 EastCleveland CavaliersCentralEastern4733
0.588​
3020105
5 EastOrlando MagicSoutheastEastern4634
0.575​
311997
6 EastIndiana PacersCentralEastern4634
0.575​
3119115
 
Upvote 0
Based on your description, I think you have the last two record reversed, as they both have the same Win% and Conf. Wins, but the last records has more Div. Wins, so should be ranked higher.

So here is what I came up with:
1712840947265.png


Here is the formula I put in cell A2 and copied down to A7:
Excel Formula:
=RANK.EQ(G2,G$2:G$7)+MAX(COUNTIFS(G$2:G$7,G2,H$2:H$7,">" & H2),COUNTIFS(G$2:G$7,G2,J$2:J$7,">" & J2))
I think it should work for most tie-breaking situations, but am not sure if there are some that it might not work for.

And then I applied a Custom Format on cells A2:A7 to get the word "East" in there:
1712841029393.png


Note: The following article helped with the tie-breaker part of the RANK function: Rank Data In Microsoft Excel With Tie Breaking • Black Atlas.
 
Upvote 0
Solution
Another option
Fluff.xlsm
ABCDEFGHIJK
1StandingTeamDivisionConferenceTotal WinsTotal LosesWin%Conf. WinsConf. LosesDiv. WinsDiv. Loses
21Boston CelticsAtlanticEastern62170.7853910151
32Milwaukee BucksCentralEastern49310.6133417107
43New York KnicksAtlanticEastern47320.5953217105
54Cleveland CavaliersCentralEastern47330.5883020105
66Orlando MagicSoutheastEastern46340.575311997
75Indiana PacersCentralEastern46340.5753119115
Data
Cell Formulas
RangeFormula
A2:A7A2=XMATCH(B2:B7,TAKE(SORT(B2:J7,{6,7,9},-1),,1))
Dynamic array formulas.
 
Upvote 1
Based on your description, I think you have the last two record reversed, as they both have the same Win% and Conf. Wins, but the last records has more Div. Wins, so should be ranked higher.

So here is what I came up with:
View attachment 109809

Here is the formula I put in cell A2 and copied down to A7:
Excel Formula:
=RANK.EQ(G2,G$2:G$7)+MAX(COUNTIFS(G$2:G$7,G2,H$2:H$7,">" & H2),COUNTIFS(G$2:G$7,G2,J$2:J$7,">" & J2))
I think it should work for most tie-breaking situations, but am not sure if there are some that it might not work for.

And then I applied a Custom Format on cells A2:A7 to get the word "East" in there:
View attachment 109810

Note: The following article helped with the tie-breaker part of the RANK function: Rank Data In Microsoft Excel With Tie Breaking • Black Atlas.
Thank you so much, this works perfectly.
 
Upvote 0
You are welcome!
Glad we were able to help!

Note that I think Fluff's formula will work a little better. There may be some weird tie-breaker scenarios that my formula could trip on (i.e. if two teams have the same in percentage, but one team has more conference wins, but the other team has more divisional wins).
So, I would probably go with his solution over mine.
 
Upvote 0
You are welcome!
Glad we were able to help!

Note that I think Fluff's formula will work a little better. There may be some weird tie-breaker scenarios that my formula could trip on (i.e. if two teams have the same in percentage, but one team has more conference wins, but the other team has more divisional wins).
So, I would probably go with his solution over mine.
It works for now but will keep an eye on it :-)
 
Upvote 0
OK. Here is an example where mine doesn't quite work and his does:
1712845413407.png
 
Upvote 0
OK. Here is an example where mine doesn't quite work and his does:
View attachment 109813

Thank you. I have factored in some other things and made necessary adjustments but using the NBA information, I'm struggling to understand how they work it out too as currently they show as Orlando Magic as 5 and Indiana Pacers as 6. Maybe their spreadsheet is wrong 🤣.

I tried to use Fluff's formula but gives me a spill error.

After some online research, the standings go by Win%( G), Games Behind (H), Div. Wins (K), Conf. Wins (I). Which all works at present except for the aforementioned 5 and 6 spots.

The new formula is this =RANK.EQ(G4,G$4:G$18)+MAX(COUNTIFS(G$4:G$18,G4,H$4:H$18,">"&H4),COUNTIFS($G$4:$G$18,G4,$K$4:$K$18,">"&K4),COUNTIFS(G$4:G$18,G4,I$4:I$18,">"&I4))

ABCDEFGHIJK
StandingTeamDivisionConferenceTotal WinsTotal LosesWin%GBConf. WinsConf. LosesDiv. Wins
1Boston CelticsAtlanticEastern62170.7850.0391015
2Milwaukee BucksCentralEastern49310.61313.5341710
3New York KnicksAtlanticEastern47320.59515.0321710
4Cleveland CavaliersCentralEastern47330.58815.5302010
6Orlando MagicSoutheastEastern46340.57516.531199
5Indiana PacersCentralEastern46340.57516.5311911
7Philadelphia 76ersAtlanticEastern45350.56317.529217
8Miami HeatSoutheastEastern44360.55018.5302013
9Chicago BullsCentralEastern37420.46825.020286
10Atlanta HawksSoutheastEastern36440.45026.522298
11Brooklyn NetsAtlanticEastern32480.40030.524265
12Toronto RaptorsAtlanticEastern25550.31337.518321
13Charlotte HornetsSoutheastEastern20600.25042.513376
14Washington WizardsSoutheastEastern15650.18847.511394
15Detroit PistonsCentralEastern13660.16549.010402


1712850087861.png
 
Upvote 0

Forum statistics

Threads
1,224,943
Messages
6,181,907
Members
453,071
Latest member
Gizmo2024

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