+ Reply to Thread
Results 1 to 7 of 7

Multiple Ranks in same cell

Hybrid View

  1. #1
    Registered User
    Join Date
    07-29-2012
    Location
    Guernsey, Channel Islands, UK
    MS-Off Ver
    Excel 2010
    Posts
    13

    Multiple Ranks in same cell

    Hi, I have a spreadsheet for race times, positions, points and then championship points. I have just found out I can use Rank to automatically fill in the positions based on the fatest time. Is there a way to be able to, in another cell, Rank the riders based on their catagory.

    eg.
    A B C D E F
    # Catagory Name Time Pos Catagory Position
    1 Senior Bob 1:10 1 1
    2 Senior Bill 1:12 3 2
    3 Junior Ben 1:11 2 1

    Above is what I would like. I have used Rank for the overall position but I would like in the catagory position column for the ranks to be separate based on the catagories.

    I have solved this by adding a hidden columns in between E and F (One saying - (If B2=Senior,D2,"") and the other Ranking this column. Then by doing the same for Junior I can split the ranks) As I have 5 catagories this adds 10 columns, then 6 rounds if the championship means 60 additional columns.

    Is there a way of doing this in one column, or at least less than 10?

    Thanks for your help, KAL46

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Multiple Ranks in same cell

    Hi and welcome to the forum

    i would suggest you upload a sample work book, (all sensitive data removed), showing what data you are working with, a few examples of what your expected outcome is, and how you arrived at that
    To attach a file to your post,
    click advanced (next to quick post),
    scroll down until you see "manage file",
    click that and select "add files" (top right corner).
    click "select files" find your file, click "open" click "upload" click 'done" bottom right. click "submit reply"

    Once the upload is completed the file name will appear below the input boxes in this window.
    You can then close the window to return to the new post screen.
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    07-29-2012
    Location
    Guernsey, Channel Islands, UK
    MS-Off Ver
    Excel 2010
    Posts
    13

    Re: Multiple Ranks in same cell

    Hi FDibbins

    Thanks for replying. I have quickly editted and attached a file. Hopefully all the notes within it explain what i'm trying to do. It makes sense to be but i've been staring at it for hours :-) Let me know if I need to clarify it more.

    Its quite in depth for a simple task but its as much a learning exercise as anything else so I would appreciate some tips.

    Thanks again, KAL46
    Attached Files Attached Files

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Multiple Ranks in same cell

    Thanks for the file. A few questions so that I can get on the same page as you...

    on sheet1 H7 down, you have
    =IF(AND(F7,G7=""),"", MIN(F7,G7))
    Is that testing to see if both F7 AND G7 are blank, to return ""? or would you want only 1 to be blank for the min() to function? reason for asking is that you are testing G7="", but you are not testing F7 for anything?

    The ranking in I14 is correct. Although H14 and H10 look the same, if you look at the values in G10 (12:01:15 AM) and G14 (4:01:15 AM), you will see that the times are different

  5. #5
    Registered User
    Join Date
    07-29-2012
    Location
    Guernsey, Channel Islands, UK
    MS-Off Ver
    Excel 2010
    Posts
    13

    Re: Multiple Ranks in same cell

    Hi again,

    The IF formula should test both are blank. Thanks for pointing out about the F7, I have now changed this to =IF(AND(F7="",G7=""),"", MIN(F7,G7)) and it works. (Its just so that with no times you don't see an error)

    Thanks also for the ranking. I changed the time and a tie break works now. I have set the format to m:ss.00 but if you don't input the colon and decimal correctly it inputs a date or hours, even though thats not the format of the cell.

  6. #6
    Registered User
    Join Date
    07-29-2012
    Location
    Guernsey, Channel Islands, UK
    MS-Off Ver
    Excel 2010
    Posts
    13

    Re: Multiple Ranks in same cell

    I have found a more efficient was of doing this. I managed to get the RANK into an IF statement.

    Therefore I still needed to split the times into seperate columns, by using the following, for each catagory type.

     IF($C7="Advanced,L7,"")
    Now with 5 columns with the times from each catagory in seperate ones I used the following, rather than 5 columns with one Rank in each. Still uses a lot of columns, but less than before.

     =IF($C7="Advanced",RANK(X7,X:X,1),IF($C7="Senior",RANK(W7,W:W,1),IF($C7="Junior",RANK(V7,V:V,1),IF($C7="Juvenile",RANK(U7,U:U,1),""))))
    Thanks for the help, hope this thread can help others,
    KAL46

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Multiple Ranks in same cell

    happy to help

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1