# Conditional probability and stistical independence

I'm really struggling to understand conditional probability and independence.

In my textbook there is this formula for two events being statistically independent:

$P(A|B) = P(A)$ or $P(B|A) = P(B)$

Please follow me in this reasoning and tell me what I'm doing wrong.

Let's say that we have a sample of 100 students and two sports to play, football and basketball, let's define $P(F)$ as the probability of playing football and $P(B)$ as the probability of playing basketball.

Let's then say that 30% of the students play football, therefore $P(F) = 0.30$. We also know that if a student is playing football, there is a 60% chance that it is playing basketball, therefore $P(B|F)= 0.60$.

From here I can calculate the probability that a student is playing football and basketball, so: $P(F and B) = P(B|F) * P(F)$ which is $P(F and B) = 0.60 * 0.30 = 0.18$

My understanding is that out of 100 students, 18 will play both basketball and football, is this correct?

Going to the independence, my understanding that two events are independent if $P(B|F) = P(B)$ means that if I start measuring all students play basketball and I find that 60 students are playing it, therefore $P(B) = 0.60$ then it means that $P(B)$ and $P(F)$ are independent, if I find out that, instead, 50 students are playing it (arbitrary number), then $P(B) and P(F)$ are dependent.

How can that possibly be true? How can a probability, $P(B|F)$ that is referred to a restricted sample space (i.e.: only people who play football) be referred to a probability for a larger sample space, i.e. the entire student community? And how can the entire number of poeple playing basketball can decide whether the two events are indepedent or not?

What is that I'm missing?

1. Claim: $P(A|B) = P(A)$ if $A$ and $B$ are independent.
Proof: Recall that if $A$ and $B$ are independent, then $P(AB) = P(A)P(B)$. Thus $$P(A|B) = \frac{P(AB)}{P(B)} = \frac{P(A)P(B)}{P(B)} = P(A)$$ where the second step is due to Bayes' rule.
2. $P(BF) = .18$ does not imply that 18 students play basketball and football. It means that there is an $18\%$ chance that a particular student plays basketball and football. To actually claim that 18 students play both, you need to count out the cases using inclusion-exclusion.
3. $P(B|F) =P(B)$ would imply independence, as defined mathematically, but this is just a toy example. You would have take samples and statistical tests to determine the independence in an actual population. As you suspect, in the real world, there is probably some relationship there.