Random Variables & Probability Functions

2022-09-15

Previously… (1/2)

Independence

[PSDR] Definition 2.20

Two events are said to be independent if knowledge that one event occurs does not give any probabilistic information as to whether the other event occurs. Formally, we say that \(A\) and \(B\) are independent if \(P(A \cap B) = P(A)P(B)\).

Events \(A\) and \(B\) are said to be dependent if they are not independent.

Conditional Probability

[PSDR] Definition 2.18

Let \(A\) and \(B\) be events in the sample space \(S\), with \(P(B) \ne 0\). The conditional probability of \(A\) given \(B\) is \[P(A|B) = \frac{P(A \cap B)}{P(B)}\]

Previously… (2/2)

Bayes’ Theorem and The Law of Total Probability

[PSDR] Definition 2.30

We say that \(A_1, \cdots, A_k\) is a partition of the sample space \(S\) if \(\bigcup_{i=1}^k A_i = S\) and \(A_i \cap A_j = \emptyset\) whenever \(i \ne j\).

[PSDR] Theorem 2.6

Let \(A_1, \cdots, A_k\) be a partition of the sample space \(S\) and let \(B\) be an event. Then,

\[P(B) = \sum_{i=i}^k P(B \cap A_i) = \sum_{i=1}^k P(A_i)P(B|A_i)\]

and

\[P(A_j|B) = \frac{P(A_j)P(B|A_j)}{\sum_{i=1}^k P(A_i)P(B|A_i)}.\]

In words,

\[\text{posterior} = \frac{\text{prior} \times \text{likelihood}}{\text{marginalization}}.\]

Example Problem 1 (1/2)

Consider a scenario where you have only one urn with contents one black ball and one red.

You draw one ball.

\(P(X = 1) = \frac{1}{2} \longrightarrow\) the probability of drawing black

\(P(X = 0) = \frac{1}{2} \longrightarrow\) the probability of drawing red

Example Problem 1 (2/2)

We can model the ball drawing using a probability function.

Example Problem 2 (1/3)

You draw one ball with replacement three times. Note that each draw are now independent events.

Example Problem 2 (2/3)

Example Problem 2 (3/3)

Drawing a Ball from an Urn \(\mathbf{n = 20}\) Times

Using the binomial probability function, we can answer probability questions much more easily.

Drawing a Ball \(\mathbf{n = 20}\) Times

Using the binomial probability function, we can answer probability questions much more easily.

The probability of observing exacty 7 black balls is \[P(X = 7) = 0.0739\]

Drawing a Ball \(\mathbf{n = 20}\) Times

Using the binomial probability function, we can answer probability questions much more easily.

The probability of observing at least 7 black balls is \[P(X \ge 7) = \sum_{x=7}^{20} P(X = x) = 0.9423\]

Discrete versus Continuous Random Variables

Discrete versus Continuous Probability Functions

Mini-Activity

Mini-Assignment: Random Variables and Probability Functions

Back to Tentative Topics Schedule.