Probability Model

Module 4 - Section 4: Probability Model

Instructor: Rosana Fok


Random Variables

  • Definition: A variable X is a random variable (rv) if its value depends on the outcome of a random event.

  • Notation:

    • Denoted by a capital letter, e.g., X.

    • A particular value of a random variable is denoted with a lowercase letter, e.g., x.

  • Examples:

    • X = number of observed "Tail" while tossing a coin 10 times.

    • X = recovery time after a specific surgery of a randomly selected patient.

    • X = high school Math mark for a randomly selected university applicant.


Types of Random Variables

  • Random variables can be categorized as:

    • Categorical

    • Quantitative

    • Quantitative random variables can be further classified into:

      • Discrete

      • Continuous

  • Implications: The models for random variables depend on their type (categorical vs quantitative); models for continuous random variables will differ from discrete random variables.


Discrete Random Variables

  • Definition: Discrete random variables can take one of a finite number of distinct outcomes.

  • Examples:

    • The number of stores in a shopping mall.

    • The number of cars owned by a family.

    • The number of luggages each traveler carries in the airport.

  • Continuous Random Variables:

    • Continuous random variables can take any numeric value within an interval of values.

    • Examples of continuous random variables:

    • Cost of books this term.

    • Height of hockey players.


Probability Model for Discrete Random Variables

  • Definition: A probability model for a random variable consists of:

    • The collection of all possible values of the random variable.

    • The probabilities that the values occur.

  • Properties of Discrete Probability Distributions:

    • For any outcome xi:

    • 0P(xi)10 \leq P(x_i) \leq 1

    • P(xi)=1\sum P(x_i) = 1

  • Table Representation:

    • Value of X: x1, x2, x3, …, xn

    • Probability: P(x1), P(x2), P(x3), …, P(xn)


Example: Tossing Coins

Unbiased Coins


  • Experiment: Toss two unbiased coins, let X equal the number of heads observed.


  • Simple Events:

    Coin 1

    Coin 2

    X

    P(X)


    H

    H

    2

    1/4


    H

    T

    1

    1/2


    T

    H

    1

    1/2


    T

    T

    0

    1/4

    • Result: Find P(X < 1).

    • Distribution for X (Number of Heads Observed):

    X

    P(X)


    ---

    ------


    0

    1/4


    1

    1/2


    2

    1/4


    Example: Tossing Biased Coins


    • Experiment: Toss two biased coins with the chance of observing a head equals 0.7.


    • Random Variables:

      • Let X = 1 if the first coin is a head, X = 0 if it is a tail.

      • Let Y = 1 if the second coin is a head, Y = 0 if it is a tail.

      • Let T = X + Y.


    • Distribution for T:

      T

      P(T)


      0

      0.09


      1

      0.42


      2

      0.49


      Expected Value: Center

      • Definition: The expected value E(X) or population mean µ (mu) of a random variable X is the value you would expect to observe on average if the experiment is repeated over and over again.

      • Relationship: It is also the center of the distribution.

      • Formula for Expected Value:
        μ<em>X=μ=E(X)=x</em>iP(xi)\mu<em>X = \mu = E(X) = \sum x</em>i P(x_i)

      • Calculation Steps:

        • Sum the products of each possible outcome and the probability that it occurs.

        • Ensure to include all possible outcomes and to verify that a valid probability model is used.


      Example: Expected Value of Coin Toss

      Unbiased Coins


      • From Previous Distribution:

        X

        P(X)


        0

        1/4


        1

        1/2


        2

        1/4

        • Expected Value Calculation:

        • μ=E(X)=0(1/4)+1(1/2)+2(1/4)=1\mu = E(X) = 0(1/4) + 1(1/2) + 2(1/4) = 1


        Example: Expected Value of Biased Coins


        • From Previous Distribution of T:

          T

          P(T)


          0

          0.09


          1

          0.42


          2

          0.49

          • Expected Value Calculation:

          • μ=E(T)=0(0.09)+1(0.42)+2(0.49)=1.98\mu = E(T) = 0(0.09) + 1(0.42) + 2(0.49) = 1.98


          Standard Deviation: Spread

          • Definition: Let X be a discrete random variable with probability distribution P(X).

          • Population Variance:
            s2<em>X=Var(X)=(x</em>iμ)2P(xi)s^2<em>X = Var(X) = \sum (x</em>i - \mu)^2 P(x_i)

          • Population Standard Deviation: The standard deviation s (sigma) of a random variable X is the square root of its variance.
            s=Var(X)s = \sqrt{Var(X)}


          Example: Variance and Standard Deviation

          Coin Toss


          • Distribution:

            X

            P(X)


            0

            1/4


            1

            1/2


            2

            1/4

            • Calculate population variance and standard deviation of X = number of heads observed.


            Example: Rolling a Die

            • Scenario: Tossing an unbiased die and recording the number on the upper face Y.

            • Expected Value Calculation:

            • μ=E(Y)=y<em>iP(y</em>i)=1(1/6)+2(1/6)+3(1/6)+4(1/6)+5(1/6)+6(1/6)=3.5\mu = E(Y) = \sum y<em>i P(y</em>i) = 1(1/6) + 2(1/6) + 3(1/6) + 4(1/6) + 5(1/6) + 6(1/6) = 3.5

            • Variance Calculation:

            • s2=(13.5)2(1/6)+(23.5)2(1/6)+(33.5)2(1/6)+(43.5)2(1/6)+(53.5)2(1/6)+(63.5)2(1/6)=2.91666s^2 = (1 - 3.5)^2(1/6) + (2 - 3.5)^2(1/6) + (3 - 3.5)^2(1/6) + (4 - 3.5)^2(1/6) + (5 - 3.5)^2(1/6) + (6 - 3.5)^2(1/6) = 2.91666

            • Standard Deviation:

              • s=2.91666=1.7078s = \sqrt{2.91666} = 1.7078


            More About Means and Variances

            • Adding/Subtracting Constants:

              • Adding or subtracting a constant from data shifts the mean but does not change the variance or standard deviation.

              • E(X±c)=E(X)±cE(X \pm c) = E(X) \pm c

              • Var(X±c)=Var(X)Var(X \pm c) = Var(X)

            • Multiplying by Constants:

              • Multiplying each value of a random variable by a constant affects the mean and variance.

              • E(aX)=aE(X)E(aX) = aE(X)

              • Var(aX)=a2Var(X)Var(aX) = a^2Var(X)


            Example: Salary Changes in a Company

            • Scenario: Monthly income for employees at ABC Company is $5830 with a standard deviation of $8000.

            • Fixed Increase:

              1. $5000 Increase:

              • The new mean:
                E(S)=5830+5000=10830E(S) = 5830 + 5000 = 10830

              • Variance remains unchanged:
                Var(S)=Var(X)=80002Var(S) = Var(X) = 8000^2

              • Standard deviation remains unchanged:
                SD(S)=8000SD(S) = 8000

              1. 10% Increase:

              • New mean:
                E(S)=1.1(5830)=6413E(S) = 1.1(5830) = 6413

              • New variance:
                Var(S)=1.12Var(X)=1.12(80002)Var(S) = 1.1^2Var(X) = 1.1^2(8000^2)

              • New standard deviation:
                SD(S)=8800SD(S) = 8800


            Two Discrete or Continuous Random Variables

            • Mean of Sum/Difference:

              • The mean of the sum (or difference) of two random variables is the sum (or difference) of the means.

              • E(X±Y)=E(X)±E(Y)E(X \pm Y) = E(X) \pm E(Y)

            • Independence and Variance:

              • If the random variables are independent, the variance of their sum (or difference) is the sum of their variances.

              • Var(X±Y)=Var(X)+Var(Y)Var(X \pm Y) = Var(X) + Var(Y)


            Combining Random Variables (The Good News)

            • Continuity: Nearly everything stated about discrete random variables also applies to continuous random variables.

            • Normality: When independent continuous random variables have Normal models, then their sum or difference also follows a Normal distribution.


            Example: Cake Baking and Decorating

            • Background: Amy and Sharon are siblings.

              • Amy averages 62 minutes to bake a cake with a standard deviation of 2 minutes.

              • Sharon averages 66 minutes to decorate a cake with a standard deviation of 4 minutes.

            • Variables:

              • Let XA = baking time (Amy).

              • Let XS = decorating time (Sharon).

              • Let T = total time = XA + XS.

            • Expected Time:

              • Calculate expected time:

              • E(T)=E(X<em>A)+E(X</em>S)=62+66=128E(T) = E(X<em>A) + E(X</em>S) = 62 + 66 = 128

            • Standard Deviation:

              • Standard deviation:

              • SD(T)=22+42=20=4.472SD(T) = \sqrt{2^2 + 4^2} = \sqrt{20} = 4.472


            Example: Probability of Time Exceeding a Limit

            • Question: If T is normally distributed, what is the probability that it will take Amy and Sharon more than 137 minutes to make a decorated cake?

              • Use Z-score to find:

              • P(T > 137) where $E(T) = 128$ and $SD(T) = 4.472$.


            Example: Redo Coin Toss

            • Goal: Use the concept of combining variables to find the population mean, variance, and standard deviation.

            • Distribution:

              • Repeat the calculations from earlier for the number of heads observed when tossing two fair coins.


            Example: Milk Production

            • Scenario: Two factories producing milk, Factory A and Factory B.

              • Factory A: Fill follows a normal distribution with mean 1.01 L and standard deviation 0.01 L.

              • Factory B: Fill follows a normal distribution with mean 1 L and standard deviation 0.01 L.

            • Probability Calculation:

              • Determine the probability that a randomly chosen carton of milk from Factory A has a higher amount of milk than from Factory B.

              • Let X be the fill of milk by Factory A, and Y be the fill of milk by Factory B.

              • Thus,

              • P(X > Y) = P(X - Y > 0)

              • The random variable XYX - Y has a normal distribution with:

                • Mean: E(XY)=1.011.00=0.01E(X - Y) = 1.01 - 1.00 = 0.01

                • Standard Deviation: SD(XY)=0.012+0.012=0.01414214SD(X - Y) = \sqrt{0.01^2 + 0.01^2} = 0.01414214

              • Final Probability:

                • P(Zk)=P(Z0.7123)=0.7611P(Z \geq k) = P(Z \geq -0.7123) = 0.7611


            Conclusion

            • Thank you for watching the video!