+ Reply to Thread
Results 1 to 69 of 69

Count games played

  1. #1
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Count games played

    I want to track how many games are played. On one sheet I have the schedule. On the other I have a list of the teams, one of the columns is a games played column. How do I count how many games have been played by each team without counting the games not played?
    Last edited by NBVC; 09-15-2011 at 07:55 AM.

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

    Re: How to count games played

    Have a look at the SUMIF and COUNTIF functions in Excel help.

    If you need more help, post a sample workbook to see your setup.
    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
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    Here's the file I'm using. I've looked at the COUNTIF and SUMIF functions and I don't quite understand how to get it to do what I want. I guess I might understand if the examples given in the help section actually worked and I could see how it works.

    Basically if a score is recorded (even if the score was zero) on the schedule, I want the GP column to show how many games they played.

    Eventually I would like to populate the other fields as well. How many points a team scored, how many were scored against them, how many wins, loses, and ties. Also I would like to have how many points the team has, 3 points for a win, 1 point for a tie, and zero points for a loss. On my Standings sheet I would like the teams to be listed according to who has the highest points.

    Is this too much for Excel maybe?
    Attached Files Attached Files

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

    Re: How to count games played

    I am guessing we are looking at the Table sheet?

    In D4:

    =COUNTIF(Schedule!B:D,B4)

    copied down counts how many times the team appears in either column B or D of Schedule sheet.

  5. #5
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    Thanks. But now how do I count them ONLY if they have played and logged a score on the schedule sheet.

    Sorry, yes on the table sheet.

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

    Re: How to count games played

    Try:

    =COUNTIFS(Schedule!B:D,B4,Schedule!A:C,"<>")

    Edited: changed to count non-blank scores.

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

    Re: How to count games played

    Edited above formula.

  8. #8
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    Thanks. It works, just not correctly. I know how many games should have been played by this point and it's not counting it right. It counts 10 when it should come up with 22. It appears to be only counting the games in column C or the left column.

    I moved the score for the home team (column on the left) to the right side of the teams, and the score for the away team (column on the right) to the right side of the teams and it works.

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

    Re: How to count games played

    With the formula above I get 22 in D4 and above 22 in all other cells in that column.

  10. #10
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    So how do I now get it to sum up the scores each team scores in the GF column on the Table page? I've been fiddling with it and it's not giving me anything. Keeps saying there is a problem with the formula. I obviously don't understand formulas very well...

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

    Re: How to count games played

    Try:

    =SUMIF(Schedule!B:D,B4,Schedule!A:C)

  12. #12
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    K, got that. Now, if I wanted goals scored against the team, how would I do that?

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

    Re: How to count games played

    Try:

    =SUMIF(Schedule!B:B,B4,Schedule!C:C)+SUMIF(Schedule!D:D,B4,Schedule!A:A)

  14. #14
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    Now here's the one that totally blows my mind. How do I count only the games they won, the games they lost and the games they tied?

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

    Re: How to count games played

    What have you tried?

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

    Re: How to count games played

    This calculates Wins:

    Please Login or Register  to view this content.
    For sumproduct you should use defined ranges instead of whole ranges...

  17. #17
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    I've tried using a couple variations of =COUNTIFS(Schedule!B:D,B4,Schedule!A:C,"<>")
    But I don't understand well enough how the formula works, in general.

    I thought:
    =COUNTIFS(Schedule!B:D,B4,Schedule!A:C,">")
    But that didn't work. I get 0, it should be 2.

    Then I thought:
    =COUNTIF(Schedule!B:D,B4)>=COUNTIFS(Schedule!B3:D308,B4,Schedule!C3:E308,"<>")
    But that gives me: TRUE
    Then I put the COUNTIF formula on the end, after the COUNTIFS formula.

    Am I even on the right track?

    (BTW I changed columns around. Column A became C and C became E)

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

    Re: How to count games played

    See my last response above...

    Because you are comparing ranges to ranges (i.e. scores to scores in A & C) and you are still checking for actual team in B and D, then Countifs doesn't work... Sumproduct is an alternate to COUNTIF in this case....

    Similar for Losses and Ties, but with ties you want to not count the blanks (no played games yet)... so need to add another condition to exclude scores:

    Please Login or Register  to view this content.
    BTW: I am going by the setup of original data... change as required to suit.
    Last edited by NBVC; 08-10-2011 at 11:38 AM. Reason: Missed a sheet reference in one range

  19. #19
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    So I was way off... Hahaha! Told ya, I'm not very good with this. Let me try my hand at the losses.

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

    Re: How to count games played

    Quote Originally Posted by geminiviper View Post
    So I was way off... Hahaha! Told ya, I'm not very good with this. Let me try my hand at the losses.
    Just wanted to check that you were actually trying

  21. #21
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    I'm getting 12... It should be 2.

  22. #22
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    Ya, I'm working at it. I just know so little about Excel. I found something to challenge myself with while I have some serious downtime...

    I get the concept of the code but not how to correct it so it shows 2 wins, not 12 wins.

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

    Re: How to count games played

    Looks like I missed a Sheetname reference at one of my ranges:

    Please Login or Register  to view this content.

  24. #24
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    Heh... I found it and was going to post that I found it to find you had just posted you found it. But, hey I found it!

    So in this calculation to get LOSSES would I flip the greater than sign to less than?

  25. #25
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    I got LOSSES by flipping the greater than sign, it worked. But when I tried to do Equal instead of a greater than or less than sign it gave a way wrong number. I got 25 and it should be 13.

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

    Re: How to count games played

    Yup.... and see post 18 for ties...

  27. #27
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    Okay, so to not count games not played then I use this thingy "<>". But I don't know where to add it and what all goes with it. I've tried adding it in a few places throughout and then adding with a Schedule!RANGE"<>" and I'm not getting it.

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

    Re: How to count games played

    Did you see post #18 above? The formula you need is there.

  29. #29
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    I did... I guess I thought it was post 16 which gave me the wins... I'm tired, it's WAY past my bedtime. (I'm currently in the middle east). Tomorrow I'll work on the Points and sorting by point leader.

    Thanks for all your help. I'm starting to understand a little bit better.

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

    Re: How to count games played

    So then so far all is good to this point?

  31. #31
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    Yes, everything is working. I managed to get the points and sorting working. Now I'm going to work on a record for at home win/loss/tie and then an away win/loss/tie and then after that a last 5 matches. But it may have to wait a bit as some very important work stuff just came up.

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

    Re: How to count games played

    Thanks for the update.

    Good luck.

  33. #33
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    So, here's my file. I have only a couple things left to put on there. I'm so lost with how Excel works though so I I know I'll need some more help. The first item on my list is not that important, I mostly want the bracket set up. My intent is to be able to reuse this later too if I wish. I can just add teams to the list and it should auto populate the rest. Here are the two things I would like to get working.

    I want to add a home win/loss/tie and an away win/loss/tie as well as a last 5 games played.

    The second thing I want to get is the bracket set up to auto fill. The bracket is set up so the top 6 teams populate from the standings page. Those are easy. The next part is not so easy. The wild card teams are determined by points. So basically the first wild card is the team with the 7th highest amount of points irregardless of conference.
    Attached Files Attached Files

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

    Re: How to count games played

    What exactly do you want filled in those new columns in Standings sheet? I.e In layman's terms what are the numbers and why?

    Also, what if there are 2 teams with 7th highest number of points?

  35. #35
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    Those blank boxes on the standings sheet are for the home win/loss/tie, away win/loss/tie and the result of the last 5 games played. Those aren't really a big deal to me but I would like to eventually have them work. Basically the home win/loss/tie would show the home record in the format of X-X-X. It's just fun to be able to see their stats at home and away. The last 5 games isn't that big of a deal, but you can see a micro trend with it. The first column with the team names on the schedule page is the home team, and the second column with teams is the away team.

    If there is a tie for any of the positions 7-10 the tie breaker would be determined by the GD column on the standings sheet. GD being the Goal Differential. The team with the higher GD wins the tie.

    Am I asking too much of Excel to be able to do that?

  36. #36
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    My thought was to use the formulas for the W, L, and T columns, which would make sense but I don't know how to make the numbers display in the format X-X-X...

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

    Re: How to count games played

    This is what I have got so far... all except the Last 5 column... I still would like to understand what you expect to see in those... give an example for the first team.

    For the Home column formula is in K4:

    Please Login or Register  to view this content.
    For Away column, in L4:

    Please Login or Register  to view this content.
    both copied down and copied to Western Conference table.

    As for the WC setup, I used a helper column in the Standings sheet to get the rankings of the teams based on Pts and GD.

    in Q4 formula is:

    Please Login or Register  to view this content.
    copied down

    then in Sheet1, B6 to get 7th:

    Please Login or Register  to view this content.
    in B10 to get 10th:

    Please Login or Register  to view this content.
    in AJ6 to get 8th:

    Please Login or Register  to view this content.
    and in AJ10 to get 9th:

    Please Login or Register  to view this content.
    So if you review those and elaborate on the definition of "Last 5", we would be set.
    Attached Files Attached Files

  38. #38
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    The Last 5 is the result of the last 5 games played. So, it would look like W-L-L-T-W, for example.

    Also, I need to go back over the scores I've input the last couple weeks because two of the teams stats aren't matching up for some reason... Probably an error on my part.

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

    Re: How to count games played

    Hmmm.. that one is not so easy... will take some time if you really want it...

  40. #40
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    It's really not that big of a deal. If I want it I'll come back for it.

    I'm having an issue with the rankings, and the auto filling for the Wildcard spots. It's not pulling the right teams.

    I've replaced the Last 5 column with a Rankings column and moved over the information from column Q to column M. I fixed the formula in the Sheet 1 page to pull the teams from, but it still isn't pulling the right teams.

  41. #41
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: How to count games played

    It looks like it's pulling correctly, there's just a hiccup in the way the bracket is formed. For example, the 6th rank team, Real Salt Lake, is not in the top 6 which would automatically qualify in the tournament. Instead they are the number two seed for the wild cards... So, I guess it's not exactly the #7-10 teams but rather the 1st-4th teams AFTER the first 3 from each conference... Does that make sense? If not see below, if so ignore below.

    As it sits right now it would look like:
    W1 - LA Galaxy
    W2 - FC Dallas
    W3 - Seattle Sounders FC
    E1 - Columbus Crew
    E2 - Philadelphia Union
    E3 - Sporting Kansas City
    WC1 - Colorado Rapids
    WC2 - Real Salt Lake
    WC3 - Houston Dynamo
    WC4 - New York Red Bulls

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

    Re: How to count games played

    See new sheet attached. Does that work?
    Attached Files Attached Files

  43. #43
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    It seems to be working perfectly. With some corrections to my data entry, of course. Thanks! You've been awesome to help me out. If only I knew half as much as you did about this... You're the bomb!

    I'm going to mark this thread as solved for now. If I decide later that I really want the Last 5 column I'll come back and revive it.

  44. #44
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    So I've missed a couple details I want to go back and cover...

    First, my sorting isn't automatic. Is there a way to make it automatic?

    Second, on the Bracket page, I want to have it autofill the bracket as I put scores in. So in the first game, the winner gets put into the box for the next game.
    Attached Files Attached Files

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

    Re: Count games played

    What is it you are sorting and sorted how?

    Where are the scores going that will be filled into the brackets. If in the Schedule sheet, how to know from where in the table to get the relevant scores, or will you enter them manually into the bracket sheet in say, C6 and C10, for example?

  46. #46
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Good questions, I was half asleep... Definitely not thorough enough with my explanation.

    On the Standings Page each conference would be sorted by who is in the lead according to points. I know how to do that manually but for some reason I was thinking it would do it on its own after I set it the first time.

    Yes, I would enter them in the C6 or C10 on the Bracket page. I figure it easiest that way so I don't have to change anything when I reuse the sheet.

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

    Re: Count games played

    The sorting won't happen automatically you need a macro.

    I added a button to the sheet and attached the following macro (which was recorded and then cleaned):

    Please Login or Register  to view this content.
    You will have to enable macros on this workbook when you open it so that you can run the code.

    Note: I also added conditional formatting to both tables on that sheet to keep the colour banding in order, so that after sorting, you will still have every other row coloured.

    In the Bracket sheet, add this formula to G8:

    =IFERROR(INDEX(B6:B11,MATCH(MAX(C6:C11),C6:C11,0)),"")

    Then copy that cell and paste to L6 and then L14

    then in Z6 enter:

    =IFERROR(INDEX(AE4:AE9,MATCH(MAX(AF4:AF9),AF4:AF9,0)),"")

    copy that cell and paste to Z14 and then to AE8
    Attached Files Attached Files

  48. #48
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Okay, I ran into a hiccup with the bracket page. They released the rules for the wildcards. It's kind of complicated so I'll try to explain it the best I can... Here goes! Sorry for the double explanation... It's complicated!

    There is an award to the team with the best regular season record, determined by who has the most points. This award is called the Supporter's Shield.

    Wildcards: Wildcard 1 plays Wildcard 4. Wildcard 2 plays Wildcard 3. This round is called the Play-In round. The LOWEST seeded wildcard team to win in the Play-In round plays the winner of the Supporter Shield. The wildcard with the HIGHEST seed plays the Conference winner of the conference opposite to the Supports shield winner. SO....

    If LA wins the Supporters Shield then the HIGHEST seeded Wildcard team enters the EAST conference and plays the top East team. The LOWEST seeded team after the play in round plays LA. So....

    If WC1 plays WC4 and WC2 plays WC3.... Lets pretend WC4 wins, they play LA (or the SS winner). WC3 wins, they play the first place team from the East conference.

    Does this make sense?

    Also, my Standings page has an issue... It's sorting the teams right except I have an issue with a tie in points. Currently the #1 and #2 teams in the East Conference have the same number of points. The #2 team (Sporting Kansas City) has the better Goal Differential (GD) and thus they should be the #1 team. On the far right the rankings column is accurate, it's just not sorting the standings page correctly. It is however, putting the teams in their correct place on the Bracket page so there is no issue there. I think I failed to mention that criteria for sorting.

    Here is my file. Thanks for looking.

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

    Re: Count games played

    Change the sorting macro to:

    Please Login or Register  to view this content.
    The rest I have to think about...
    Last edited by NBVC; 09-13-2011 at 02:56 PM. Reason: ranges should be from column M....

  50. #50
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Thanks a lot. I changed the macro, I see what you did, it really wasn't as complicated as I thought it would be.

    So here is my updated file. I made some changes to the bracket page in hopes of making it make more sense. One thing I tried to do is make a box for the winner of the cup. In the top middle of the page is a box for this. I attempted to make it work but it's not working. What did I do wrong with the code?

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

    Re: Count games played

    Sorry, I think the ranges in the code above should have started in B.... it's been a while since we last played with this...

    Also, having a bit of difficulty understanding your new requirement.

    In the attachment you posted, are all the current formulas in the Bracket sheet ok and given expected results?

    Is it only a formula for L21 and P21 that we need?

    if so, can you try repeating the explanation more slowly using what is there on the stats currently.

  52. #52
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Sure, no problem. I wanted to put the winner of the cup game (K10vP10) in cell L3. I put a formula in there but it's not working so I was wondering what I did wrong. All other formulas on the Bracket page are working as expected to. When I populate scores into the appropriate boxes the correct result populates in the next box in the bracket.

    The ranges in the macro were supposed to be for B column but I fixed it.

    Did you want another explanation of the Wildcard/Supporter's Shield rules?
    Here goes anyway.

    The Supporter's Shield Winner is the team with the highest points at the end of the regular season. I want this team to go in cell L17.

    At the bottom of the page I have the Wildcard Play-In round. Each team is labeled as such:
    WC1
    WC2
    WC3
    WC4

    WC 1 plays WC4 and WC2 plays WC3.
    The winners will be placed in cells L28 and P28 with the WC# in the cell to the left (K28 and O28 respectively)

    From there, the team with the lowest WC# (lowest seed) will play the team who wins the Supporter's Shield. Here's an example.

    If WC1 and WC2 both win their games they advance to the regular playoff tournament. Who they play is determined by their seed. Thus, WC2 is the LOWEST seed and will play the winner of the Supporter's Shield.

    The Supporter's Shield winner will be either from the West or the East. The WC# that is highest, in this scenario WC1, will play the conference winner from the conference opposite of the Supporter's Shield winner. If the team from the West, LA, wins the Supporter's Shield, WC1 will play the winner from the East Conference (currently Sporting Kansas City).

    Does that make sense?

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

    Re: Count games played

    The formula for L3 is easy enough:

    =IFERROR(INDEX(K10:O10,MATCH(MAX(M10,Q10),(M10:Q10),0)),"")

    or even

    =IF(OR(M10="",Q10=""),"",IF(M10>Q10,K10,O10)) which you can also, incidentally, adapt to all your other 2nd round selections....if desired..


    I review your new explanation for the other part....

  54. #54
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    So, my formula was off by one thing... I put a comma where a colon should have been... Not bad I say.

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

    Re: Count games played

    So, so far in L17:

    =IFERROR(INDEX(Standings!B4:B25,MATCH(1,Standings!M4:M25,0)),"")

    in L28:

    =IFERROR(INDEX(G26:G31,MATCH(MAX(H26:H31),H26:H31,0)),"")

    in P28:

    =IFERROR(INDEX(U26:U31,MATCH(MAX(V26:V31),V26:V31,0)),"")

    is that correct so far?

    Where are the results for all this:

    From there, the team with the lowest WC# (lowest seed) will play the team who wins the Supporter's Shield. Here's an example.

    If WC1 and WC2 both win their games they advance to the regular playoff tournament. Who they play is determined by their seed. Thus, WC2 is the LOWEST seed and will play the winner of the Supporter's Shield.

    The Supporter's Shield winner will be either from the West or the East. The WC# that is highest, in this scenario WC1, will play the conference winner from the conference opposite of the Supporter's Shield winner. If the team from the West, LA, wins the Supporter's Shield, WC1 will play the winner from the East Conference (currently Sporting Kansas City).
    supposed to go?

  56. #56
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Close. In L28 and P28, the cells to the left of each, K28 and O28 I wanted the Wildcard number. So just keep the two cells, WC1 and Real Salt Lake together. Does that make sense?

    The results go in cells B8 and O28. As long as the lowest seed team plays the Supporter's Shield winner and the highest seed team plays the other conference winner. Does that make sense?

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

    Re: Count games played

    Ok, in K28:

    =IFERROR(INDEX(F26:F31,MATCH(L28,G26:G31,0)),"")

    in O28:

    =IFERROR(INDEX(T26:T31,MATCH(P28,U26:U31,0)),"")

    To get lowest Seed... I assume WC1 is lower than WC2, you had the reverse...

    =IFERROR(IF(RIGHT(K28)<RIGHT(O28),L28,P28),"")

    if I am wrong, then reverse the < to a >

    To get the Higher seed:

    =IF(B8=L28,P28,L28)

    where B8 contains the Lowest seed winner from the first formula above.

    to get the highest in opposing conference to the SS Winner:

    =IF(MATCH(1,Standings!M4:M25,0)>9,Standings!B4,Standings!B17)

    The SS winner:

    =INDEX(Standings!B4:B25,MATCH(1,Standings!M4:M25,0))
    Last edited by NBVC; 09-13-2011 at 04:30 PM.

  58. #58
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    The K28 and O28 formulas are not showing correctly. They just show the formula.

    The lowest seed team of the wildcards would be WC4, the highest would be WC1 because the team with the best record gets the WC1 spot and the team with the worst (qualifying) record gets WC4...

    I'm not sure where to put the rest of the codes... It's not guaranteed that LA or anyone else from the West Conference for that matter, will win the Supporter's Shield...

  59. #59
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Nevermind, K28 and O28 are showing correctly, copy and paste didn't work right.

  60. #60
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Nevermind on the other stuff too. I got it. I'm now doing a complete test to make sure it is correctly showing how it should.

  61. #61
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    That is it. Everything works the way it should work. If I wanted to change the color of the lines on the standings page, how would I do that? I tried just changing them but that didn't work and then I looked in the Macro (I didn't think it would be there) and didn't see it there. I'm not sure where else to look.

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

    Re: Count games played

    While in one of the cells of the Eastern Conference standings, go to Home tab, Conditional Formatting, Manage Rules.. Select and Edit the rule and change the colour by clicking Format and going to Pattern tab.

    Then repeat for the Western Conference Standings...

    Note: Once completed, can you kindly post the final workbook for the benefit of future users who might find this helpful.

    Thanks.
    Last edited by NBVC; 09-13-2011 at 09:40 PM.

  63. #63
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Thanks to NBVC who, if you read this whole threat, did all the work. I didn't realize how complicated some of the formulas were. Thanks for being so patient and willing to help me out.

    This is a tracker for the US Major League Soccer. There are three tabs, Schedule, Standings, and Bracket. The file is designed to automatically populate on its own, where you only need put data into the Schedule page. The data needed to be input is the date, home team (left column) away team (right column) and the result of the game. The date is not entirely important except that if there is a game to be played today the date will be highlighted yellow.

    Once the score of the game is put in the correct spot the Standings page will populate. Based on the standings page the Bracket page will also populate.

    The Wildcard rules are based on the 2011 season rules which may or may not be the same in future years. They have been fairly similar for years so this should work. The only reason any of this will need to be changed is with the addition of new teams, which happens every couple years. To add another team just insert a cell for the proper conference and type in the name of the team. How the tournament rules change may determine whether this bracket will work or not.

    I added a couple pictures for the fun of it, and to give it a little aesthetics.

    Thanks for all the help.

  64. #64
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    So, everything is not working as it should. I have discovered that the Bracket page has an error in applying the Wildcard spots. Wildcards 1-3 are showing the correct teams, but WC4 is showing the wrong team. It looks as if the code is searching only the East Conference.

    To be specific, WC4 should belong to Portland, but the sheet is showing New York. I'm not sure but it looks like it's only looking in the East for the WC4 spot, but the wildcards can go to any team in any conference, as long as they have the most points. Just to recap the Wild Card rules:

    Wild Cards are awarded to the 4 teams with the highest total points (Goal Differential acts as the tie breaker) behind the 3rd place teams in either conference. Therefore... As the season stands.
    East
    1 - Columbus Crew
    2 - Sporting Kansas City
    3 - Philadelphia Union

    West
    1 - LA Galaxy
    2 - Real Salt Lake
    3 - Seattle Sounders

    By points the Wild Cards should be as follows
    WC1 - FC Dallas (46 points)
    WC2 - Colorado Rapids (41 points)
    WC3 - Houston Dynamo (39 points)
    WC4 - Portland Timbers (37 points)

    New York has 36 points and is showing as WC4, I think because it's only looking in the east conference for that spot.


    This forum is not letting me change the status from SOLVED to not solved...
    Last edited by geminiviper; 09-22-2011 at 04:01 PM.

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

    Re: Count games played

    I think this one will require some array formulas, which unfortunately can't be used in merged cells... so you will need to calculate them outside the merged cells somewhere, then have a simple formula pointing to those cells in the merged boxes.

    So for WC1:

    Please Login or Register  to view this content.
    WC2:

    Please Login or Register  to view this content.
    WC3:

    Please Login or Register  to view this content.
    WC4:

    Please Login or Register  to view this content.
    [B]each will have to be confirmed with CTRL+SHIFT+ENTER[/B] not just ENTER to work

    You can then point to them with simple formulas.

    So for example if you put the WC1 array formula in cell AP1, then in G26 just enter =AP1

    and so on.

  66. #66
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Perfect, that works nicely. Thanks!

    I tested and double tested. It works as it should.

  67. #67
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Wow... So it doesn't work 100%, it's about 99% though. I found an issue I didn't consider. In the standings I have two teams with the same number of points and the same GD (Goal Differential) but they are from different conferences. So, I have Houston from the East who is in the second place spot for the East Conference and I have Colorado who is the 5th place team in the West Conference.

    The problem is that because Houston is tied with Colorado for 6th place overall (in the ranking created for this spreadsheet) Houston is showing up in the #2 Wild Card spot, but they are also showing up in the East Conference #2 spot. Being the #2 in the conference puts them on the bracket already thus they don't need to be considered for a wildcard spot.

    It should look like this:
    East Conference
    Philadelphia
    Houston
    Sporting Kansas City

    West Conference
    LA
    Seattle
    Real Salt Lake

    Wild Cards
    Dallas
    Colorado
    Columbus
    New York

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

    Re: Count games played

    I see. Ok, change the formulas in L42, P42, P43 and L43, respectively to these:

    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    each confirmed with CTRL+SHIFT+ENTER.

  69. #69
    Registered User
    Join Date
    08-10-2011
    Location
    St. Louis, MO
    MS-Off Ver
    Excel 2007
    Posts
    46

    Re: Count games played

    Okay, that fixed that issue... Man these tiebreakers are breaking this thing...

    I saw another thread on here about how to decide a tiebreaker based on the head-to-head rule. Which is whichever team has the best winning record against the team they are tied against. At this point, can this be incorporated into the spread sheet?

    Sporting KC and Philadelphia are both tied in points and the first tie breaker is whoever has the best record against the other team. Since the two teams play each other twice it could still end in a tie. If the first tiebreaker fails then the second is who has the better Goal Differential.

    In this particular case, Sporting KC and Philadelphia both have 48 points, and they tied each other in both of their games, and they both have a GD of 9, so the next tie breaker is total goals. Is it possible to incorporate all of this in this sheet?

    Here are the first 3 tiebreaker rules.
    The highest position shall be awarded to the team with the better win–loss record in current regular-season games against all other teams equal in points. (head-to-head competition)

    If the teams are still equal in the standings, the highest position shall be awarded to the team with the greater goal difference against all other teams during the regular season. (goal differential)

    If the teams are still equal in the standings, the highest position shall be awarded to the team scoring the greatest number of total goals against all other teams during the regular season. (total goals)

+ 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