+ Reply to Thread
Results 1 to 12 of 12

Help - Count Top 10 Winners

  1. #1
    Registered User
    Join Date
    08-08-2012
    Location
    USA
    MS-Off Ver
    mac excel 2011
    Posts
    10

    Help - Count Top 10 Winners

    I have many list like the one attached.

    Over 200 of them.

    Each list contains a list of companies people submitted.

    I need to find the top 10 vote getting companies from each list.

    sample.xls

    Can anybody think of a way to help me do this?

    Many times people will enter the same company, but spell it differently.

    I was thinking about creating some kind of pivot table that counted unique words from the column while and adding the associated number.

    I guess I first need to create a column that strips out the number in the parentheses first.

    The file I attached as a sample is how they are turned into me.

    Any help is appreciated.

    Thank you!

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Help - Count Top 10 Winners

    Extract the company name with formula in B1:

    =TRIM(LEFT(A1,FIND("|",TRIM(SUBSTITUTE(A1,"(","|",LEN(A1)-LEN(SUBSTITUTE(A1,"(","")))))-1))

    copied down

    Extract number with formula in C1:

    =MID(LEFT(A1,LEN(TRIM(A1))-1),FIND("|",TRIM(SUBSTITUTE(A1,"(","|",LEN(A1)-LEN(SUBSTITUTE(A1,"(","")))))+1,10)

    Insert row above with headers, then do your Pivot Table.
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Valued Forum Contributor
    Join Date
    05-08-2012
    Location
    Georgia, USA
    MS-Off Ver
    Excel 2003, 2010
    Posts
    811

    Re: Help - Count Top 10 Winners

    To get you started, this formula strips out the name and numbers:

    NAME
    =TRIM(LEFT(A1,LEN(A1)-FIND("(",A1)))

    NUMBER
    =VALUE(MID(A1,FIND("(",A1)+1,FIND(")",A1)-FIND("(",A1)-1))

    As mentioned above use a pivot table
    Last edited by K m; 08-08-2012 at 11:27 AM.
    Click on star (*) below if this helps

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Help - Count Top 10 Winners

    Some of the names have additional parentheses in them, that is why mine looks a bit more complicated... but as K m shows, the number formula I gave should be enclosed in a VALUE() function, or simply adding +0 to the end, to coerce it into a true number and not a text string, which is what MID() returns...

    i.e.

    =MID(LEFT(A1,LEN(TRIM(A1))-1),FIND("|",TRIM(SUBSTITUTE(A1,"(","|",LEN(A1)-LEN(SUBSTITUTE(A1,"(","")))))+1,10)+0

  5. #5
    Registered User
    Join Date
    08-08-2012
    Location
    USA
    MS-Off Ver
    mac excel 2011
    Posts
    10

    Re: Help - Count Top 10 Winners

    Thank you NBVC and K m.

    I tried over and over again to use your four equations.

    But I kept getting #name? errors.

    I looked at them closely but couldn't figure out what could be wrong.

    I am afraid I am going to have to tally up the winners the old fashion way.

    Thank you again,

    Tyler

  6. #6
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Help - Count Top 10 Winners

    Here is my formulas in action....
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    08-08-2012
    Location
    USA
    MS-Off Ver
    mac excel 2011
    Posts
    10

    Re: Help - Count Top 10 Winners

    Well, I have two problems.

    I have spliced together a .xlsb file the best I could.

    The two problems I have are:

    One: Column 5, I can't get cells below row 24 to fill in properly. When I copy the formula above it, it just repeats with "Zios"

    This column is supposed to be a list of unique words from column 3, but only listing the words once.

    Two: Column 6, I want to find the occurrence of the word from RC[-1] not the exact phrase from RC[-1], then add together the value from column 4 when that word from column 5 appears in column 3.

    Then as a bonus, I am hoping to create a new sheet that list the top 30 values from column 6 with it's corresponding unique word from column 5, in descending order.

    Wow, did that make sense?

    Here is my file so far, if anybody wants to download it and fix it for me, that would be wonderful!

    Unique-distinct-words1 Tyler.xlsb.zip

    (I had to .zip compress it first because the site wouldn't let me upload the .xlsb file.)

  8. #8
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Help - Count Top 10 Winners

    I am afraid I can't help you enough with your UDF's. It's out of my current scope here. The formulas I gave you did what you had originally asked for.

    You probably should post a new thread in the Programming forum regarding this part of the problem.

  9. #9
    Registered User
    Join Date
    08-08-2012
    Location
    USA
    MS-Off Ver
    mac excel 2011
    Posts
    10

    Re: Help - Count Top 10 Winners

    Thank you NBVC very much.

    I barely know what I am doing and you were a big help.

    I will try the programming area.

  10. #10
    Registered User
    Join Date
    08-08-2012
    Location
    USA
    MS-Off Ver
    mac excel 2011
    Posts
    10

    Re: Help - Count Top 10 Winners

    Yea, I figured out problem one.

    Now trying to figure out problem two.

  11. #11
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Help - Count Top 10 Winners

    Go to the Forum Index, select your forum, click New Thread/New Topic

  12. #12
    Registered User
    Join Date
    08-08-2012
    Location
    USA
    MS-Off Ver
    mac excel 2011
    Posts
    10

    Re: Help - Count Top 10 Winners

    I can't believe it.

    All figured out and I could not of done it without everybody's help.

    It was a lot of fun too figuring everything out.

+ 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