Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
CONTINUOUS RANDOM VARIABLES Continuous random variables take all values in an interval Too many values! Impossible to list them all! How to describe a continuous random variable? Density curve of random variable X Use density curve. P(a ≤X < b)=area under the density curve between a and b. Total area under density curve =1. P(a<X<b) a b X Values of X Continuous density example -uniform distribution X-time (min) taken by a fire truck to arrive at a fire after 911 call. Suppose X is equally well anywhere between (2, 15) min. X r.v. with uniform distribution on (2, 15). Density curve for X has the same height over (2, 15): rectangle. Area=1. Length (2, 15) is 13 height=1/13. Density of X P(5<X<8) 1/13 0 2 5 8 15 Probability that it takes between 5 and 8 min for the fire truck to arrive: P( 5<X < 8) = Area between 5 and 8=3 x (1/13)=3/13. MEAN AND VARIANCE OF A RANDOM VARIABLE Measures of center and spread of a r.v. X – discrete r.v. X has probability distribution: Values of the r.v X x1 x2 … xn probabilities p1 p2 … pn Center of the distribution: mean, Expected value of X, EX or E(X): n µ = EX = x1 p1 + x2 p2 + ⋯ + xn pn = ∑ xi pi i =1 NOTES: The mean represents the “long-run-average” value of X. If we average many values of X, we expect to get a number close to EX. EX is a weighted average of the values of X, weights are the probabilities of the values. VARIANCE and STANDARD DEVIATION OF A RANDOM VARIABLE Measures of spread around the mean µ of a random variable. X discrete rv Variance of X Take squared deviations from the mean and add them up with the same weights as for the mean: VarX=Var(X)= σ2 = (x1 – µ)2 x p1+ (x2 – µ)2 x p2 + … + (xn – µ)2 x pn= n = ∑ ( xi − µ ) 2 × pi . i =1 Standard deviation of X: σ = σ 2 = VarX . NOTES: Both variance and standard deviation of any random variable are nonnegative. If X is continuous use calculus to define and compute mean and variance. NO WORRIES IN STAT152. EXAMPLE The number of defective chips produced in a month by a company ABCHIP has the following probability distribution: Number of defective chips 0 10 15 20 probabilities 0.1 0.2 0.5 0.2 a. What is the average number of defective chips this company produces in a month? b. What is the standard deviation of the number of defective chips this company produces in a month? Solution. a. X=# of defective chips produced by ABCHIP in a month. EX= µ = 0 x 0.1 + 10 x 0.2 + 15 x 0.5 + 20 x 0.2 = 13.5 Note that the mean is not one of the possible values of X! b. VarX= σ2 = (0-13.5)2 x 0.1 + (10 – 13.5)2 x 0.2 + (15 – 13.5)2x 0.5+(20-13.5)2x 0.2 = 30.25. Standard deviation of X, σ = VarX = σ2 = 30.25 =5.5. EXAMPLE Your winnings on a lottery are a random variable with the following probability distribution: Winnings in $ 100 200 1,000 0 Probabilities 0.4 0.2 0.3 ? a. Find the probability that you win $1,000. b. What is the probability that you will win at least $150? c. What is your expected winning? Solution. X= winnings in $. a. Since sum of all probs=1, then P(X=1,000)=1-(0.4+0.3+0.2)=0.1. b. P(X ≥ $150)=P(X=$200 or X=$1,000)=0.3 +0.1=0.4. c. EX = 0 x 0.2 + 100 x 0.4 + 200 x 0.3 +1,000 x 0.1= 200. You should expect to win about $200 if you play for a long time. EXAMPLE What if we consider that you must pay $10 to play the lottery. What are your expected winning then? The probability distribution of the winnings changes to accommodate the payment. Winnings in $ 90 190 990 -10 Probabilities 0.4 0.3 0.1 0.2 The negative $10 means you lose $10 with probability 0.2. EX= -10 x 0.2 + 90 x 0.4 + 190 x 0.3 +990 x 0.1 = 190. You should expect to win about $190 if you play for a long time.