#1   Report Post  
Junior Member
 
Posts: 4
Default Ranking function

I'm tracking Nascar stats in a workbook consisting of several sheets. I'm manually entering all data consisting of drivers starts, finishes, wins, etc. The issue I'm having is ranking the drivers by several categories, one beings laps led. The formulas I have seem to work with the exception that when two or more drivers have led the same number of laps, it lists one of the drivers twice. Right now, as an example, one charts reads:

Rank Driver # Laps Led
17 Sam Hornish 36
18 Marcos Ambrose 35
18 Marcos Ambrose 35
20 AJ Almendinger 33

At this point in the season M Ambrose and M Kenseth are tied for leading 35 laps. I would like the 3rd name in the list to read M Kenseth.

On my sheet I have column B setup with drivers names, column C with laps led. My Laps leaders charts consists of 4 columns. The 1st column (AD) is for whose led most laps (descending order) with formula: =IF(AF2=0,"",RANK(AF2,$AF$2:$AF$21)) - 2nd column is name of driver (AE) with formula =INDEX(B:B,MATCH(LARGE($C:$C,ROWS($A$1:A$1)),$C:$C ,0)) - 3rd column (AF) lists total laps led & formula =INDEX(C:C,MATCH(LARGE($C:$C,ROWS($A$1:A$1)),$C:$C ,0)) - 4th & final column I put in what I thought might be a tiebreaker column (AG) with formula =IF(C2="","",C2+ROW()/10^10.

I'm not having any luck with the formulas relisting the drivers names properly. I don't know if I'm overdoing it with the formulas that I have. I'm thinking I might need to use the CounIF function but I'm so lost right now I'm not sure How it needs to be used.

Any help would be greatly appreciated.

Doug
  #2   Report Post  
Senior Member
 
Location: Philippines
Posts: 161
Default

Quote:
Originally Posted by doverfield View Post
I'm tracking Nascar stats in a workbook consisting of several sheets. I'm manually entering all data consisting of drivers starts, finishes, wins, etc. The issue I'm having is ranking the drivers by several categories, one beings laps led. The formulas I have seem to work with the exception that when two or more drivers have led the same number of laps, it lists one of the drivers twice. Right now, as an example, one charts reads:

Rank Driver # Laps Led
17 Sam Hornish 36
18 Marcos Ambrose 35
18 Marcos Ambrose 35
20 AJ Almendinger 33

At this point in the season M Ambrose and M Kenseth are tied for leading 35 laps. I would like the 3rd name in the list to read M Kenseth.

On my sheet I have column B setup with drivers names, column C with laps led. My Laps leaders charts consists of 4 columns. The 1st column (AD) is for whose led most laps (descending order) with formula: =IF(AF2=0,"",RANK(AF2,$AF$2:$AF$21)) - 2nd column is name of driver (AE) with formula =INDEX(B:B,MATCH(LARGE($C:$C,ROWS($A$1:A$1)),$C:$C ,0)) - 3rd column (AF) lists total laps led & formula =INDEX(C:C,MATCH(LARGE($C:$C,ROWS($A$1:A$1)),$C:$C ,0)) - 4th & final column I put in what I thought might be a tiebreaker column (AG) with formula =IF(C2="","",C2+ROW()/10^10.

I'm not having any luck with the formulas relisting the drivers names properly. I don't know if I'm overdoing it with the formulas that I have. I'm thinking I might need to use the CounIF function but I'm so lost right now I'm not sure How it needs to be used.

Any help would be greatly appreciated.

Doug
Could you attach a sample of your workbook here?
__________________
Asobi Wa Owari Da
  #3   Report Post  
Junior Member
 
Posts: 4
Default

Yes, I'd be delighted to. The issue I'm having is located on the Miles Leaders Tab. Columns AD to AL consists of one of four categories that I' trying to figure out.
  #4   Report Post  
Junior Member
 
Posts: 19
Default

Quote:
Originally Posted by doverfield View Post
Yes, I'd be delighted to. The issue I'm having is located on the Miles Leaders Tab. Columns AD to AL consists of one of four categories that I' trying to figure out.
Hi,

Have you tried just sorting the columns. No Formulas needed. Double sort will give "equal" drivers in Alpha order.

Educo
  #5   Report Post  
Junior Member
 
Posts: 4
Default

Quote:
Originally Posted by David of XL Plus View Post
Hi,

Have you tried just sorting the columns. No Formulas needed. Double sort will give "equal" drivers in Alpha order.

Educo
No, I never thought of that. I'd have to rearrange some small charts but will give it a whirl. Thank you


  #6   Report Post  
Junior Member
 
Posts: 4
Default

Quote:
Originally Posted by wickedchew View Post
Could you attach a sample of your workbook here?
The Column to the left consists of the drivers names (not all of them listed due to space limitations; set up as column B2) and next column (C2) showing number of laps led. The Chart to the right I wish to sort the top 20 drivers with the most laps. The 18th place driver is showing up twice, although he is tied with another driving for same # of laps led.

The Ranked column (AD) I have the formula =IF(AF2=0,"",RANK(AF2,$AF$2:$AF$21)). The column with the drivers names (AE) I have the formula =INDEX(B:B,MATCH(LARGE($C:$C,ROWS($A$1:A$1)),$C:$C ,0)). The number of laps led column (AF) I have formula =INDEX(C:C,MATCH(LARGE($C:$C,ROWS($A$1:A$1)),$C:$C ,0)).

I hope the image I attached is enough to go by. I know the website will not allow me to send the entire file but hope this will help. I appretiate any assistance in the matter. For any further questions or information please let me know.

Thank you for your time.

Doug
Attached Images
 
  #7   Report Post  
Senior Member
 
Location: Philippines
Posts: 161
Default

Quote:
Originally Posted by doverfield View Post
The Column to the left consists of the drivers names (not all of them listed due to space limitations; set up as column B2) and next column (C2) showing number of laps led. The Chart to the right I wish to sort the top 20 drivers with the most laps. The 18th place driver is showing up twice, although he is tied with another driving for same # of laps led.

The Ranked column (AD) I have the formula =IF(AF2=0,"",RANK(AF2,$AF$2:$AF$21)). The column with the drivers names (AE) I have the formula =INDEX(B:B,MATCH(LARGE($C:$C,ROWS($A$1:A$1)),$C:$C ,0)). The number of laps led column (AF) I have formula =INDEX(C:C,MATCH(LARGE($C:$C,ROWS($A$1:A$1)),$C:$C ,0)).

I hope the image I attached is enough to go by. I know the website will not allow me to send the entire file but hope this will help. I appretiate any assistance in the matter. For any further questions or information please let me know.

Thank you for your time.

Doug
Since there is a tie in your table, I would suggest to use this formula for your RANK function to prevent duplicates.

=RANK(AF2,$AF$2:$AF$21)+COUNTIF(AF2:$AF$21,AF2)-1
__________________
Asobi Wa Owari Da
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Ranking without preset Excel function. a.riva@UCL Excel Worksheet Functions 0 October 16th 07 05:53 PM
Ranking or sorting function craig Excel Worksheet Functions 4 June 4th 07 03:51 PM
Ranking Function casdaq Excel Worksheet Functions 4 March 15th 07 04:50 AM
Ranking linzi00 Excel Discussion (Misc queries) 2 October 5th 06 05:42 PM
need function to sum top ranking items in list QuantumPion Excel Worksheet Functions 13 June 6th 05 10:42 AM


All times are GMT +1. The time now is 06:02 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"