# Deriving the Joint conditional binomial distribution

Combinatorics questions I've seen so far tend to come with numbers. Those I do by having the number of event combinations on the number of possible combinations. That works because I the space is uniform.

What If I instead have different probabilities for different possible outcomes?

Say 10% of people wear blue, 30% of people wear green and 60% of people wear red. 10 customers come into my store. Then If we have an event A, what is the probability of A occurring?

Suppose A= {2 people wear red}, then this is just a binomial distribution.

But suppose I want to calculate multivariate binomial events say, B ={less than 2 wear red and less than 2 wear blue}. Would this require a joint conditional binomial distribution? How would one go about deriving this?

This is my attempt at the joint pmf of the binomial. You are now taking the 2 probabilities and so you need to find all the combinations of it in n, hence $\binom{n}{x_1+x_2}$. and you're taking combinations of what is now, 2 different probabilities and the compliment which is $(1-p_{x_1}-p_{x_2})^{n-x_1 -x_2}$

$f(x_1,x_2)=\binom{n}{x_1+x_2}p_{x_1}^{x_1}p_{x_2}^{x_2}(1-p_{x_1}-p_{x_2})^{n-x_1 -x_2}$

is it correct? is making a joint binomial pmf the best way to find P(B)?

$$\mathbb P(B=b, G=g, R=r \mid B+G+R=b+g+r) = \frac{(b+g+r)!}{b! g! r!}p_{\text{blue}}^b p_\text{green}^gp_\text{red}^r$$
This is in fact more or less to what you wrote except that where you have $\binom{n}{x_1+x_2}$ you should have had something like $\frac{n!}{x_1! \, x_2! \, (n-x_1-x_2)!}$ or $\binom{n}{x_1+x_2}\binom{x_1+x_2}{x_1}$ or $\binom{n}{x_1}\binom{n-x_1}{x_2}$