1 / 25

Expected values and variances

Expected values and variances. Formula. For a discrete random variable X and pmf p(X): Expected value: Variance: Alternate formula for variance: Var(x)=E(X^2)-[E(X)]^2 Standard Deviation: =sqrt(variance). Answers to some questions.

Download Presentation

Expected values and variances

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Expected values and variances

  2. Formula • For a discrete random variable X and pmf p(X): • Expected value: • Variance: • Alternate formula for variance: • Var(x)=E(X^2)-[E(X)]^2 • Standard Deviation: =sqrt(variance)

  3. Answers to some questions Assuming you are playing a poker game, each player gets 13 cards. On average, how many aces should you have at your hand?

  4. Average number of Aces Let X= number of aces a player has at hand. Then X is a discrete random variable since it can only take values of 0, 1, 2, 3 and 4. We want to find its pmf and then find its expected value. pmf

  5. Average number of Aces • The average number of aces a player has at hand is the expected value of this discrete random variable X, • 0*0.3038+1*0.4388+2*0.2134+3*0.0412+4*0.0026=0.9998, almost 1. • That means if you play poker many, many times, and if you add up the total number of Aces you have got and find its average, it should be around 1.

  6. Calculating variance and standard deviation for number of Aces

  7. Average number of Aces The variance and standard deviation of the number of Aces are therefore: Var(X)= 0.457710023, Std. Dev.= 0.676542699 The interpretation of variance and standard deviation will be more meaningful if we have an underlying distribution. But here, we do not. The best we can say is that the number of Aces changes quite a bit, since you can only have at most 4 Aces.

  8. Average number of Aces An important thing here is that, the variance and standard deviation we calculate here are for “number of Aces”. It is a very common mistake that people may say they are for “the average number of Aces”. That is WRONG!!!. Both expected value and variance(std. dev.) are used to summarize the number of Aces you have at hand. The summary for the “average number of Aces” is totally a different issue.

  9. Average number of suits Assuming you are playing a poker game, each player gets 13 cards. On average, how many different suits should you have at your hand?

  10. Average number of suits Let Y=number of suits a player has at hand. It is also a discrete random variable whose pmf is:

  11. Average number of suits • The average number of suits a player has at hand is the expected value of the discrete random variable Y, • E(Y)=1*1.57^(-12)+2*0.0001+3*0.051+4*0.9489 =3.9488, almost 4. • That means you will almost always have all four suits in your hand.

  12. Variance and standard deviation

  13. Variance and standard deviation The variance and standard deviation of the number of suits in your hand are: Var(Y)= 0.04877856 Std. Dev. 0.220858688 Again, they are for “number of suits in your hand”, not for “average number of suits in your hand”.

  14. Purpose of the above two examples 1. How to put a given problem in probability terms ( define the random variable of interest, find its sample space, etc ). 2. How to find the pmf of the random variable. 3. How to find the expected value and variance given the pmf of the random variable. The above two examples are for discrete random variables, the procedure is similar to continuous random variables.

  15. Another Example • If you toss a fair coin three time and let X= the number of heads observed. Find the expected value and variance of X. • There are different ways to solve this problem. • From the three tosses, we have a total of 8 outcomes. • {HHH, HHT, HTH, THH, HTT, THT, TTH, TTT} • Each of the above 8 outcomes has a probability of 1/8.

  16. Coin Toss Example • One way of finding the mean is to count the number of heads in each outcome and take the average. • {3, 2, 2, 2, 1, 1, 1, 0} • The mean is therefore 12/8=1.5 • Then we can find the variance of the 8 numbers, which is: • [(3-1.5)^2+3*(2-1.5)^2+3*(1-1.5)^2+(0-1.5)^2]/8=0.75

  17. Coin Toss Example Another way is to find the pmf. E(X)=0*(1/8)+1*(3/8)+2*(3/8)+4*(1/8)=1.5 Var(X)=(0-1.5)^2*(1/8)+(1-1.5)^2*(3/8)+(2-1.5)^2*(3/8)+(3-1.5)^2*(1/8)=0.75

  18. Coin Toss Example Yet another way. In probability, there is something we call Bernoulli and Binomial trials, which are repetitions of exactly the same experiments with two possible outcomes. In this case, we repeat the experiment of tossing a fair coin 3 times, each time with 50% chance of getting head and 50% chance of getting tail.

  19. Coin Toss Example That is a Binomial experiment, or we say the (discrete) random variable X follows a Binomial distribution. For Binomial distribution, the outcomes can be summarized with a pmf that does not have to look like a table, but like a function instead. Use our knowledge:

  20. Coin Toss Example • There are easier ways to find the expected value and variance of a Binomial random variable. • If X~BIN(n,p) • E(X)=np • Var(X)=np(1-p) • In this case, n=3, p=0.5, so E(X)=np=3*0.5=1.5 and Var(X)=3*0.5*0.5=0.75

  21. Properties of Expected Values and Variances E(X+Y)=E(X)+E(Y) E(X+c)=E(X)+c E(aX+bY)=aE(X)+bE(Y) For example, if E(X)=5 and E(Y)=6, then E(X+5)=5+5=10 E(2X+5)=2*5+5=15 E(3X+2Y)=3*5+2*6=27

  22. Properties of Expected Values and Variances Var(X+Y)=Var(X)+Var(Y), if X and Y are independent. Var(aX)=(a^2)Var(X) Var(X+c)=Var(X) Var(aX+bY)=(a^2)Var(X)+(b^2)Var(Y), if X and Y are independent.

  23. Properties of Expected Values and Variances • Example: if Var(X)=4 and Var(Y)=9, X and Y are independent. • Var(2X+3Y)=4*Var(X)+9*Var(Y)=4*4+9*9=97

  24. Properties of Expected Value and Variances Example: if you roll a 6-sided fair die and win $3 based on the number you get, e.g., you get $6 if you roll a 2 and $15 if you roll a $15. Let Y be the money you collect from playing this game what is the expected value and variance of Y.

  25. Properties of Expected Values and Variances Let X be the outcome of rolling a fair die, then Y=3*X. Since we know E(X)=3.5, E(Y)=3*3.5=$10.5 and Var(Y)=(3^2)Var(X)=9*3.5=31.5 The standard deviation is sqrt(31.5)=$5.61 Note: Mean and standard deviation have the same unit.

More Related