Daniel S Yates The Practice of Statistics Third

  • Slides: 34
Download presentation
Daniel S. Yates The Practice of Statistics Third Edition Chapter 7: Random Variables 7.

Daniel S. Yates The Practice of Statistics Third Edition Chapter 7: Random Variables 7. 2 The mean and Standard Deviation of a Random Variable Copyright © 2008 by W. H. Freeman & Company

Some of the examples and slides were copied from the following source: Roxy Peck

Some of the examples and slides were copied from the following source: Roxy Peck Chris Olsen Jay Devore Introduction to Statistics & Data Analysis 3 ed Thompson Brooks/Cole, a part of The Thompson Corporation

Essential Questions • How do you calculate the mean of a discrete random variable?

Essential Questions • How do you calculate the mean of a discrete random variable? • How do you calculate the variance and standard deviation of a discrete random variable? • What is the law of large numbers? • Given µX and µY, How do you calculate µa+b. X and µX+Y ? • Given X and Y are independent, how do you calculate σ2 a+b. X and σ2 X+Y ? • How do you describe the shape of a linear combination of independent Normal random variables?

Review

Review

Review

Review

Review

Review

Calculating The Means of a Discrete Random Variable Distribution

Calculating The Means of a Discrete Random Variable Distribution

Example 1 • A professor regularly gives multiple choice quizzes with 5 questions. Over

Example 1 • A professor regularly gives multiple choice quizzes with 5 questions. Over time, he has found the distribution of the number of wrong answers on his quizzes is as follows

Example Continued • Multiply each x value by its probability and add the results

Example Continued • Multiply each x value by its probability and add the results to get mx. mx = 1. 41

Example – Apgar Scores • At I min after birth and again at 5

Example – Apgar Scores • At I min after birth and again at 5 min, each newborn child is given a numerical rating called the Apgar score. Possible values of the score are 0, 1, 2, …, 9, 10. A child’s score is determined by five factors: muscle tone, skin color, respiratory effort, strength of heartbeat, and reflex. A high score indicates a healthy baby. Let X denote the Apgar score at I min of a randomly selected newborn infant at a particular hospital. The probability distribution is: X 0 P(X). 002 1 2 3 4 5 6 7 8 9 10 . 001 . 002 . 005 . 02 . 04 . 17 . 38 . 25 . 12 . 01 What is the mean Apgar score at this hospital? µX = 7. 16

Calculating Variance

Calculating Variance

Example 1 Again • A professor regularly gives multiple choice quizzes with 5 questions.

Example 1 Again • A professor regularly gives multiple choice quizzes with 5 questions. Over time, he has found the distribution of the number of wrong answers on his quizzes is as follows µX = 1. 41 Calculate the variance for the of X.

Example - continued

Example - continued

Example – Apgar Score Again X 0 P(X). 002 1 2 3 4 5

Example – Apgar Score Again X 0 P(X). 002 1 2 3 4 5 6 7 8 9 10 . 001 . 002 . 005 . 02 . 04 . 17 . 38 . 25 . 12 . 01 µX = 7. 16 Find the variance and standard deviation for the discrete random variable X.

Number of Observations versus Accurate Estimates of μ

Number of Observations versus Accurate Estimates of μ

Rules for Means and Variances

Rules for Means and Variances

Suppose • Suppose we want to find the means length and Standard Deviation of

Suppose • Suppose we want to find the means length and Standard Deviation of a species of grasshoppers in a particular field. We run our survey and establish the following distribution: • X = the length in inches X P(X) 1 0. 2 2 0. 5 3 0. 3 • Find the mean and standard deviation of X. μX = 2. 1 inches σ2 X = 0. 49 σ = 0. 7 inches

More Supposing X (in. ) 1 2 3 μX = 2. 1 in. P(X)

More Supposing X (in. ) 1 2 3 μX = 2. 1 in. P(X) 0. 2 0. 5 0. 3 σ2 X = 0. 49 • Suppose we are required to report our findings using the metric system. How does changing to centimeters affect µX and σX ? 2. 54 X 2. 54(1) 2. 54(2) 2. 54(3) P(X) 0. 2 0. 5 0. 3 µ 2. 54 X = 2. 54(1)(0. 2) + 2. 54(2)(0. 5) + 2. 54(3)(0. 3) = 2. 54[(1)(0. 2) + (2)(0. 5) + (3)(0. 3)] = 2. 54[ 2. 01] = 2. 54µx ----- Let b = 2. 54, then bµx σ22. 54 X = (2. 54(1) – 2. 54(2. 1))2 (0. 2) + (2. 54(2) – 2. 54(2. 1))2 (0. 5) + (2. 54(3) – 2. 54(2. 1))2 (0. 3) = (2. 54(-1. 1))2 (0. 2) + (2. 54(-0. 1))2 (0. 5) + (2. 54(0. 9))2 (0. 3) = 2. 542 ((-1. 1)2 (0. 2) + (-0. 1)2 (0. 5) + (0. 9)2 (0. 3)) = 2. 542 (0. 49) = 2. 542 σ2 X -------- b 2σ2 X

Even More Supposing • We discover after the survey that the instruments we used

Even More Supposing • We discover after the survey that the instruments we used to measure the grasshopper were miss calibrated. The measurements were 0. 1 inches too short. Is there a way to adjust the results without re-doing the entire survey? • 0. 1 inches =. 254 cm. 254 + 2. 54 X . 254 + 2. 54 . 254 + 5. 08 . 254 + 7. 62 P(X) 0. 2 0. 5 0. 3 µ. 254+2. 54 X = (. 254 + 2. 54)(0. 2) + (. 254 + 5. 08)(0. 5) + (. 254 + 7. 62)(0. 3) =. 254(. 2) +. 254(. 5) +. 254(. 3) +2. 54(. 2) + 5. 08(. 5) +(7. 62)(. 3) = [. 254(. 2) +. 254(. 5) +. 254(. 3)] +[2. 54(. 2) + 5. 08(. 5) +(7. 62)(. 3)] =. 254[ 1(. 2) + 1(. 5) + 1(. 3)] + 2. 54[ 1(. 2) + 2(. 5) + 3(. 3)] =. 254 + 2. 54µX If we let a =. 254 and b = 2. 54, then we have µa+b. X = a + bµx

Rules for Means

Rules for Means

Example 2 Suppose x is the number of sales staff needed on a given

Example 2 Suppose x is the number of sales staff needed on a given day. If the cost of doing business on a day involves fixed costs of $255 and the cost per sales person per day is $110, find the mean cost (the mean of x or mx) of doing business on a given day where the distribution of x is given below.

Example 2 continued We need to find the mean of y = 255 +

Example 2 continued We need to find the mean of y = 255 + 110 x

Example 2 continued We need to find the variance and standard deviation of y

Example 2 continued We need to find the variance and standard deviation of y = 255 + 110 x

Means and Variances for Linear Combinations If x 1, x 2, , xn are

Means and Variances for Linear Combinations If x 1, x 2, , xn are random variables with means m 1, m 2, , mn and variances and respectively, y = a 1 x 1 + a 2 x 2 + + anxn then 1. my = a 1 m 1 + a 2 m 2 + + anmn (This is true for any random variables with no conditions. ) 2. If x 1, x 2, , xn are independent random variables then and

Example 3 A distributor of fruit baskets is going to put 4 apples, 6

Example 3 A distributor of fruit baskets is going to put 4 apples, 6 oranges and 2 bunches of grapes in his small gift basket. The weights, in ounces, of these items are the random variables x 1, x 2 and x 3 respectively with means and standard deviations as given in the following table. Apples Oranges Grapes Mean m Standard deviation s 8 10 7 0. 9 1. 1 2 Find the mean, variance and standard deviation of the random variable y = weight of fruit in a small gift basket.

Example 3 continued It is reasonable in this case to assume that the weights

Example 3 continued It is reasonable in this case to assume that the weights of the different types of fruit are Apples Oranges Grapes independent. Mean m Standard deviation s 8 10 7 0. 9 1. 1 2

Example 4 • A nationwide standardized exam consists of a multiple choice and a

Example 4 • A nationwide standardized exam consists of a multiple choice and a free response section. Each section, the mean and standard deviation are reported to be: Mean Multiple Choice 38 Free Response 30 Standard Deviation 6 7 • Let X 1 = the score for multiple-choice and X 2 = the score for the free response. • Suppose the total score is computed as Y = X 1 + 2 X 2 • Find the mean and standard deviation for the test

Example 4 Continued The Mean The Standard Deviation Are X 1 and X 2

Example 4 Continued The Mean The Standard Deviation Are X 1 and X 2 independent? It is likely that X 1 and X 2 are not independent since a person who does well on multiple choice section will also do well on the free response section and vice versa. Therefore, we can not calculate the standard deviation with the given information.

Last Problem • Suppose that the mean height of policemen is 70 inches with

Last Problem • Suppose that the mean height of policemen is 70 inches with a standard deviation of 3 inches. And suppose that the mean height for policewomen is 65 inches with a standard deviation of 2. 5 inches. • If heights of policemen and policewomen are Normally distributed, find the probability that a randomly selected policewoman is taller than a randomly selected policeman.

Last Problem - Continued • Let X = height of policewoman and Y= height

Last Problem - Continued • Let X = height of policewoman and Y= height of policeman. • μX-Y = 65 – 70 = -5. • σ2 X-Y = σ2 X + σ2 Y = 2. 52 + 32 = 15. 25 • σX-Y = • Using N(-5, 3. 905) find P(X –Y < 0). From the Calculator ( Norm. CDF ( -9999, 0, -5, 3. 905) P(X – Y < 0) = 0. 8997

Summary • The Law of Large Numbers says that the average of the values

Summary • The Law of Large Numbers says that the average of the values of X observed in many trials approach μ. • If X is discrete with the possible values xi, the means is the average of the values of X, each weighted by its probability: μX = x 1 p 1 + x 2 p 2 + … + xnpn • The variance σ2 for a discrete variable: σ2 X = (x 1 - μ)2 p 1 + (x 2 – μ)2 p 2 + … + (xn - μ)2 pn • The standard deviation σX is the square root of the variance.

Summary The means and variance of random variables obey the following rules • If

Summary The means and variance of random variables obey the following rules • If a and b are fixed numbers, then μa + b. X = a + b μX σ2 a+b. X = b 2σ2 X • If X and Y are any two random variables, then μX + Y = μX + μY • And if X and Y are independent, then σ 2 X + Y = σ 2 X + σ 2 Y σ 2 X – Y = σ 2 X + σ 2 Y