How to calc total number of possible lineups from a given player pool?

Take your daily fantasy game to the next level.
Login Register

Someone asked me how to do this and since I'm no math wiz I started to reply to him that it was too complicated for my math challenged mind but as I was typing I couldn't help but think it through and I think I actually figured it out. I was hoping someone with math chops could double check me and make sure I've got this right.

First thing we need to do is figure out total number of RB and WR combinations right?

n Choose r or C(n,r) So C(RB,2) C(WR,3).

Then we need to get the total number of flex players. So Flex = ((RB+WR+TE) -6) We have to subtract 6 from the total because we will already be using 6 of those players from the RB, WR, TE pool.

Now we just multiply those with the totals from the other positions together to get the total number of possible lineups correct?

Total number of possible lineups = QB * C(RB,2) * C(WR,3) * TE * ((RB+WR+TE) -6) * DST

So if we have a player pool with 5 players at each position it would be

5 * (C(5,2)=10) * (C(5,3)=10) * 5 * (((5+5+5)-6)=9) * 5 = 112,500 possible lineup combinations


5 * 10 * 10 * 5 * 9 * 5 = 112,500

I put this into a quick, simple google spreadsheet using the COMBIN(n,r) function to get the RB/WR sets and it seems to be working fine and seems to be correct but I wanted someone who actually has a clue look it over and make sure I'm not missing something.


8 years ago

I think the answer to your 5 player question is 120 found by 5x4x3x2x1

You can use 5! as the formula on a calculator to find the answer easier.

And since itsbuilding a lineup it doesn't allow for repeating numbers.

The problem you are going to run into is that the formula needs to know to differentiate all the players in the pool separated by a position. That way it's not calculating teams of nine players per se with all quarterbacks orall running backs

8 years ago

No I'm looking for the total number of possible lineup combinations. Factorials (n!) tells us how many ways we could order a set without repeating. So if we had a set of five letters (A B C D E) there are 120 ways to order that set without repeating.



C A B D E and so on.

Imagine if we only had 2 positions, QB and RB, we have 5 players in the pool at each position and we only use one of each position in each lineup. There are 5 * 5 = 25 possible combinations

QB1, RB1

QB1, RB2

QB1, RB3

QB1, RB4

QB1, RB5

QB2, RB1...and so on for a total of 25 combos.

If you have 5 each RB and WRs that is 10 combinations of 2 RB and 10 combinations of 3 WR alone. Even if you only had one player at each other position and no flex position that would be 100 possible lineups.

8 years ago

You are math challenged? I beg to differ SIR! Your calculations look OK to me. But its also scary and makes me want to severely limit my player pool because that kind of diversification (112,000+) is not possible for me on a DFS site. Especially with what is going on these days even if they were all 0.25 cent games.

8 years ago

Turns out I did miss something. I asked the mathematics community on stackexchange and someone was kind enough to point out the error.

The way I did it would allow for the flex to double count TE's, triple count RB's and quadruple count WR's.

In other words, if the flex was a TE and we had 5 TE's named A B C D and E the way I did it would allow for a lineup with A at TE and E at flex but also allow for a lineup with E at TE and A at flex. Both lineups would be the same. The calculation needs to be broken down into cases where one case the flex is a RB the second case flex is a WR and third case flex is a TE then add those three results together. So you choose 3 X RB one time then 4 X WR and finally 2 X TE and then add those together.

The correct calculations for my example with 5 players in each position pool is;

((QB * C(RB, 3) * C(WR, 3) * TE * DST) + (QB * C(RB, 2) * C(WR, 4) * TE * DST) + (QB * C(RB, 2) * C(WR, 3) * C(TE, 2) * DST))

(5 * 10 * 10 * 5 * 5) = 12,500 where the flex is a RB

(5 * 10 * 5 * 5 * 5) = 6,250 where flex is a WR

(5 * 10 * 10 * 10 * 5) = 25,000 where flex is a TE

25,000 + 12,500 + 6,250 = 43,750 total unique lineup combinations.

I knew 112,500 seemed way too high for a pool of 5 players at each position.

BTW @Odie n! is used in the n choose r function. C(RB, 3) = C(5, 3) = 5! / [3! * (5-3)!] = 10

8 years ago

You are the Math King!

8 years ago

I didn't check the details - but bobby_j's approach looks correct.

Note - you don't really know how many of those lineups are valid with respect to the team and more importantly the budget constraints. There would be no closed form expression for that.

8 years ago

Right, thanks for mentioning that Dr. Galati.

I know this is not a practical solution it was just a #lineups from a given player pool with no other considerations. It was fun to try and think it through.

8 years ago

I’ve been using your formula to calculate the total number of options given just my own playerpool. This year we have a new option you may be familiar with. Showdown? Ok so given a 5 spots played evenly for every 1 captain spot how would you calculate? I also like to know how this might change given certain variables to be true. I’ve been researching nfl showdown perfect lineups and found the following to be true. In any of the perfect lineups since nfl showdowns have stared we know the following: no kickers ever, always at least 2wr and one defense. I’m not sure that part is relavent to figuring out how many different possible options there are but I thought I would include it. I also thought I would ask another question. I’ve been 100% correct on my playerpool but not had every correct person in a lineup together. Would it be easier to formulate given my playerpool? Say I have 24 players in my pool how many possible different combinations could one get out of 24 players with 6 different flex positions in a showdown

5 years ago
  • Reply