Conditional probability asks how likely event A is when event B is already known to have happened. Written as P(A|B), it means “the probability of A given B.” section 1.3
Rain in the Amazon
Suppose A means “it rains today” and B means “we live in the Amazon rainforest.” If P(A|B) = 0.8, rain has an 80% probability given that location. The additional information changes the estimate. section 1.3
New information can update a probability:
- Without clues, the probability that an unknown animal is a dog may be small. section 8.0
- Learning that it is a house pet raises the estimate; learning that it has wings reduces the estimate to zero. section 8.0
- Bayes’ theorem formalizes this updating, while naive Bayes simplifies the calculation when there are many features. section 8.0
In machine learning, conditional probability connects observed features to likely labels: a classifier can estimate whether a sentence is happy given its words or whether an email is spam given its contents. section 8.0













