Presentation is loading. Please wait.

Presentation is loading. Please wait.

Chapter 16 Random Variables

Similar presentations


Presentation on theme: "Chapter 16 Random Variables"— Presentation transcript:

1 Chapter 16 Random Variables
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley

2 Expected Value: Center
A random variable assumes a value based on the outcome of a random event. We use a capital letter, like X, to denote a random variable. A particular value of a random variable will be denoted with a lower case letter, in this case x.

3 Expected Value: Center (cont.)
There are two types of random variables: Discrete random variables can take one of a finite number of distinct outcomes. Example: Number of credit hours Continuous random variables can take any numeric value within a range of values. Example: Cost of books this term

4 Expected Value: Center (cont.)
A probability model for a random variable consists of: The collection of all possible values of a random variable, and the probabilities that the values occur. Of particular interest is the value we expect a random variable to take on, notated μ (for population mean) or E(X) for expected value.

5 Expected Value: Center (cont.)
The expected value of a (discrete) random variable can be found by summing the products of each possible value by the probability that it occurs: Note: Be sure that every possible outcome is included in the sum and verify that you have a valid probability model to start with.

6 Expected Value – Example #1
An insurance company offers a “death and disability” policy that pays $10,000 when you die or $5000 if you are disabled. It charges a premium of only $50 a year for this benefit. Suppose the death rate is 1/1000 and another 2/1000 will be disabled. Is the company likely to make a profit selling such a plan? Come up with a probability model Find the expected value

7 Policy Outcome x = payout probability
Death 10,000 1/1000 Disability ,000 2/1000 Neither /1000 Expected Value for 1000 people: 10,000 for 1 person 5,0000 for 2 people 0 for 997 people = 20,000 payout or $20 per policy So company has an average profit of $30 for every policy

8 Expected Value Example #2
One of the authors took his minivan in for repair. The mechanic identified the problem as dirt in the control unit. He said that in about 75% of such cases, drawing down an recharging the coolant a couple of times cleans up the problem and costs $60. If it fails, then the control unit must be replaced at an additional cost of $100 for parts and $40 for labor. A) Define the random variable and construct a probability model B) what is the expected value of the cost of the repair? C) what does that mean in this context?

9 Answer Outcome x= cost probability recharging $60 .75 works
Replace unit $ 60(.75) + 200(.25) = $95 Car owners with this problem will spend an average of $95 to get it fixed

10 Back to the Insurance problem…
No individual policy actually costs the company $20 – most cost $0 Since we are dealing with random events, some policyholders receive big payouts, others nothing B/c insurance company must anticipate this variability, we need to know the standard deviation from the mean

11 Remember standard deviation?
How far from the average To compute we took the deviation (difference) from the mean and squared it – called variance Take the square root to get the standard deviation

12 Finding Standard Deviation Example
Using the data from example #1, find the standard deviation

13 Policy Outcome x = payout probability Deviation Death 10,000 1/1000 ( ) = 9980 Disability 5,000 2/1000 ( ) = 4980 Neither 0 997/1000 (0-20) = -20 To Find the Variance: Var(X) = (1/1000) (2/1000) + (-20) 2 (997/1000) = 149,600 SD = Square Root 149,600 = $ The insurance company can expect an average payout of $20 per policy, with a standard deviation of $ So this means that although payout is small there is a big risk (Spread) for an average profit of $30

14 First Center, Now Spread…
For data, we calculated the standard deviation by first computing the deviation from the mean and squaring it. We do that with random variables as well. The variance for a random variable is: The standard deviation for a random variable is:

15 Practice As the head of inventory for a computer company, you ship 2 computers to your client the day the order arrived. You find out that someone had restocked refurbished computers in with new computers. The shipped computers were selected randomly from 15 computers in stock, 4 of those were refurbished . If your client gets 2 new computers, things are fine. If the client gets one refurbished computer, it will be sent back at your expense $100 and you can replace it. If both are refurbished, the client will cancel and you’ll lose $1000. What’s the expected value and standard deviation of your loss?

16 How do you find the Mean and Standard Deviation in Calculator?
Using the previous example: STAT – Edit - L1: enter values of variable (0,100,1000) L2: enter probability model (.524,.419, .057) STAT CALC - 1: VarStats L1, L2 – enter X = mean σ = standard deviation

17 More About Means and Variances
Adding or subtracting a constant from data shifts the mean but doesn’t change the variance or standard deviation: E(X ± c) = E(X) ± c Var(X ± c) = Var(X) Example: Consider everyone in a company receiving a $5000 increase in salary.

18 More About Means and Variances (cont.)
In general, multiplying each value of a random variable by a constant multiplies the mean by that constant and the variance by the square of the constant: E(aX) = aE(X) Var(aX) = a2Var(X) Example: Consider everyone in a company receiving a 10% increase in salary.

19 More About Means and Variances (cont.)
In general, The mean of the sum of two random variables is the sum of the means. The mean of the difference of two random variables is the difference of the means. E(X ± Y) = E(X) ± E(Y) If the random variables are independent, the variance of their sum or difference is always the sum of the variances. Var(X ± Y) = Var(X) + Var(Y)

20 Example #5 Suppose the time it takes a customer to get and pay for seats at the ticket window of a baseball park is a random variable with a mean of 100 seconds and a standard deviation of 50 seconds. When you get there, you find 2 people in line How long do you expect to wait for your turn to get tickets? What’s the standard deviation of your wait time? What assumption did you make about the 2 customers in finding the standard deviation

21 Answer 100 + 100 = 200 seconds √502 + 502 = 70.7 seconds
The times for the two customers are independent

22 Continuous Random Variables
Random variables that can take on any value in a range of values are called continuous random variables. Continuous random variables have means (expected values) and variances. We won’t worry about how to calculate these means and variances in this course, but we can still work with models for continuous random variables when we’re given the parameters.

23 Continuous Random Variables (cont.)
Good news: nearly everything we’ve said about how discrete random variables behave is true of continuous random variables, as well. When two independent continuous random variables have Normal models, so does their sum or difference. This fact will let us apply our knowledge of Normal probabilities to questions about the sum or difference of independent random variables.

24 Example #6 The times required to pack a stereos can be described with a Normal model with a mean of 9 minutes and standard deviation of 1.5 minutes. The times for the boxing stage can also be modeled as Normal, with a mean of 6 minutes and standard deviation of 1 minute What is the probability that packing two consecutive systems takes over 20 minutes What percentage of the stereo systems take longer to pack than to box?

25 What Can Go Wrong? Probability models are still just models.
Models can be useful, but they are not reality. Question probabilities as you would data, and think about the assumptions behind your models. If the model is wrong, so is everything else.

26 What Can Go Wrong? (cont.)
Don’t assume everything’s Normal. Watch out for variables that aren’t independent: You can add expected values for any two random variables, but you can only add variances of independent random variables.

27 What Can Go Wrong? (cont.)
Don’t forget: Variances of independent random variables add. Standard deviations don’t. Don’t forget: Variances of independent random variables add, even when you’re looking at the difference between them. Don’t forget: Don’t write independent instances of a random variable with notation that looks like they are the same variables.

28 What have we learned? We know how to work with random variables.
We can use a probability model for a discrete random variable to find its expected value and standard deviation. The mean of the sum or difference of two random variables, discrete or continuous, is just the sum or difference of their means. And, for independent random variables, the variance of their sum or difference is always the sum of their variances.

29 What have we learned? (cont.)
Normal models are once again special. Sums or differences of Normally distributed random variables also follow Normal models.


Download ppt "Chapter 16 Random Variables"

Similar presentations


Ads by Google