I am trying to gain basic understanding on how to calculate probabilities. Below are a few examples of what I am trying to calculate. I would prefer (if possible) for formulas to be given on how to solve these using Microsoft Excel. Also, educating me on Probability Terminology involved would be helpful.

Situation 1:
I am going to draw "X" cards (5, for 5-card stun poker) from a "Y" card deck (52), what are the odds of getting a flush in hearts (Variable I have labeled as "Z" = 13... in my current ignorance, I refer to this as the "Targets" variable)?

My algebraic solution:
= (13/52) * (12/51) * (11/50) * (10/49) * (9/48)
Solution to chance of getting any flush would be the above times 4 to represent a flush in any suit.

The problem with the above solution is that it becomes impractical when the situational probabilities I am trying to calculate become more complicated.

QUESTION 1: What is a more statistical way of calculating the above? (using excel)

Situation 2:
I am going to draw "X=5" 5 cards from a "Y=10" 10 card deck. In this deck there are only two different draw possibilities, Card 1 or Card 2... There are 7 copies of Card 1 which are all identical and 3 copies of Card 2 which are all identical.

What is the probability of getting 0-3 copies of Card 2?

X = 5, Y = 10, Z = 3

QUESTION 2: What is the statistical way of calculating the above? (using excel)

Situation 3:

X = 7, Y = 60, Z = 20

QUESTION 3: How do I calculate, using excel, what the odds are of getting 0-7 of the target cards in a draw of 7?

2 Answers
2

While computing the probabilities directly using algebra are possible, it's much easier to take an approach based on combinatorics.

We can do this using binomial coefficients, which are sometimes read as "Choose $k$ from $n$ objects," or "n Choose k."

Basically, for the chances of any flush of clubs, you need to compute the probability of choosing 5 out of 13 cards out of the 52 card deck. Probability is, of course, represented by a number $0 \le p \le 1$, so what we want to compute is the number of possible flushes of clubs, and divide it by the total number of hands.

The total number of hands can be written as $\begin{pmatrix} 52 \\ 5\end{pmatrix} = \frac{52!}{5!(52-5)!}$. The total number of club flushes (including straight and royal flushes) is $\begin{pmatrix} 13 \\ 5\end{pmatrix}$, or "choose any 5 from 13 total cards." So your probability is $$P(\mathrm{club flush}) = \begin{pmatrix}13 \\ 5 \end{pmatrix}/\begin{pmatrix}52 \\ 5\end{pmatrix}.$$

You can extend this arbitrarily. Say you want the probability of any flush. Well, obviously it's better, because there are four possible suits. So you want to multiply the previous result by the number given by "choosing one suit for the flush out of four possible suits," or $\begin{pmatrix}4 \\ 1\end{pmatrix}$, resulting in

That is the general approach to answer your first question. To answer your second question, we can do the same thing: You want to know the probability that if you choose 5 cards, you will get between 0 and 3 copies of a 2.

To answer questions 2 and 3, which can be handled quite similarly, we have 10 cards, and draw 5. So the total possible number of hands is $\begin{pmatrix}10 \\ 5\end{pmatrix}$. Right now, it doesn't matter that all of the Card 1s/Card 2s are the same -- we're going to formulate the problem in such a way that it doesn't matter.

To choose 0 Card 2s in 5 cards is the same thing as saying "choose 0 out of 3 card 2s, and choose 5 out of 7 card 1s." Using the combinatorical technique described above, that's $\begin{pmatrix}3 \\ 0\end{pmatrix}\begin{pmatrix}7 \\ 5\end{pmatrix}$. Moving on, choosing 1 Card 2 is like saying "choose 1 out of 3 Card 2s, and 4 out of 7 Card 1s," or $\begin{pmatrix}3 \\ 1\end{pmatrix}\begin{pmatrix}7 \\ 4\end{pmatrix}$. Continue this for each value 0,1,2,3, and add up the results. This gives you the total number of events; to get the total probability, divide that by the total number of possible events, $\begin{pmatrix}10 \\ 5\end{pmatrix}$.

(Note that in example 2, there are only three Card 2s, so you should have a 100% probability of picking between 0 and 3 (inclusive) Card 2s in the draw.)

The solution is exactly the same for Question 3.

To compute these numbers in Excel, $\begin{pmatrix}10 \\ 5\end{pmatrix}$ can be computed using

@DiabloMonkey Ah, I see what the problem is. The numerator is the product of "Choosing D Card2 from 3 total Card2" and "Choosing (5-D) Card1 from 7 total Card1" Therefore, you should be using (3,0)(7,5) instead of (5,0)(7,5). The top numbers in your coefficients should equal the total number of cards in the deck.
–
ArkamisAug 3 '12 at 16:28

That fixed the problem. Thank you for the help.
–
DiabloMonkeyAug 3 '12 at 16:45

I realized my typo that resulted from some careless copy-pasta; I have updated my answer to be more correct! Sorry for the confusion!
–
ArkamisAug 3 '12 at 18:14

Question 1:
You notice how for question 1, you did something like (13!/8!)/(52!/47!), in other words, you did (13!/(13-5)!)/(52!/(52-5)!).
Let A1 be the "X" Cards and let B1 be "Y" Cards, and C1 is "Z", then for the answer cell D1, you have:

D1 = (FACT(C1)/FACT(C1-A1))/(FACT(B1)/FACT(B1-A1))
Actually, when you do X!/(X-Y)!, that is just a PERMUTATION method where you chose Y things out of X things, so xPy. So the answer is C1=PERMUT(C1,A1)/PERMUT(B1,A1)

Question 2:
I am guessing when you say "0-3" copies you mean you want 4 answers. Let's make the amount of Card 2's (lets make them red, and card 1's blue) you want D1. For example, lets make D1=2. So what is the probability that out of the 5 cards you draw, 2 of them will be card 2. Algebraically, if you want the first two cards to be be red, first realize that there are 5!/(2!*3!) ways to arrange 2 red cards in a hand of 5. Selecting the cards 2s gives a chance of 3/10*2/9 while the blue cards give 7/8*6/7*5/6. Now lets put this in equation format.
5!/(2!*3!) -> COMB(A1, D1)
Red cards(numerator) -> PERMUT(C1, D1)
Blue Cards(numerator) -> PERMUT(B1 - C1, A1 - D1)
Denominator -> PERMUT(B1, A1)
What does that give us in the end?Answer=E1=(COMB(A1, D1) * PERMUT(C1, D1) * PERMUT(B1-C1, A1-D1))/PERMUT(B1, A1). Just make D1 = 0, 1, 2, and 3

Question 3 is the same deal.

I am positive about my solution to question 1, but someone might wanna check the other two.

Thank you so much for explaining this (including factorial and combinatorical solutions)... I had forgotten about combinatorics (well, I still knew they existed but I had forgotten how to use them). I am still curious about how to solve the 2nd and 3rd parts... but trying to figure it out myself.
–
DiabloMonkeyAug 3 '12 at 15:37

DiabloMonkey, I made one huge mistake. It should be Permutations, not combinations. Use the PERMUT Command. I will edit my answer.
–
mathguyAug 3 '12 at 15:40

Except in question 2, one of the things is still a combination.
–
mathguyAug 3 '12 at 15:43

Question... Your answer E1=(COMBIN(x,a)*PERMUT(z,a)*PERMUT(y-z,x-a))/PERMUT(y,x)) works just the same as Ed Gorcenski's E1=(COMBIN(z,a)*COMBIN(y-z,x-a))/COMBIN(y,x)... What is the difference? The first seems to have 1 extra step, but it is using permutations instead of combinations?
–
DiabloMonkeyAug 3 '12 at 18:00

1

@DiabloMonkey: If you remember that PERMUT(a,b)=a!/(a-b)! and COMBIN(a,b)=a!/((b!)(a-b)!) and work through the algebra, you will see they are the same.
–
Ross MillikanAug 6 '12 at 13:59