WorldClass Statistics · Probability

Random variables

’s often useful to model a process using what’s called a random variable. Such a model allows us to apply a mathematical framework and statistical principles for better understanding and predicting outcomes in the real world.

Example 3.54

Two books are assigned for a statistics class: a textbook and its corresponding study guide. The university bookstore determined 20% of enrolled students do not buy either book, 55% buy the textbook only, and 25% buy both books, and these percentages are relatively constant from one term to another. If there are 100 students enrolled, how many books should the bookstore expect to sell to this class?


Around 20 students will not buy either book (0 books total), about 55 will buy one book (55 books total), and approximately 25 will buy two books (totaling 50 books for these 25 students). The bookstore should expect to sell about 105 books for this class.

Guided Practice 3.55

Would you be surprised if the bookstore sold slightly more or less than 105 books?1

Example 3.56

The textbook costs $137 and the study guide $33. How much revenue should the bookstore expect from this class of 100 students?


About 55 students will just buy a textbook, providing revenue of $137×55=$7,535\begin{aligned} \$137 \times 55 = \$7,535 \end{aligned} The roughly 25 students who buy both the textbook and the study guide would pay a total of ($137+$33)×25=$170×25=$4,250\begin{aligned} (\$137 + \$33) \times 25 = \$170 \times 25 = \$4,250 \end{aligned} Thus, the bookstore should expect to generate about $7,535+$4,250=$11,785\$7,535 + \$4,250 = \$11,785 from these 100 students for this one class. However, there might be some sampling variability so the actual amount may differ by a little bit.

A probability distribution, which appears similar to a histogram. The horizontal axis is "Cost" and runs from 0 to 170. The vertical axis is Probability. There are three bars: a bar with height 0.2 at 0, a bar with height 0.55 with height 137, and a bar with height 0.25 at 170. A red triangle is shown at the mean, located at 117.85.

Figure 3.18. Probability distribution for the bookstore’s revenue from one student. The triangle represents the average revenue per student.

Example 3.57

What is the average revenue per student for this course?


The expected total revenue is $11,785, and there are 100 students. Therefore the expected revenue per student is $11,785/100=$117.85\$11,785/100 = \$117.85.

Expectation

We call a variable or process with a numerical outcome a random variable, and we usually represent this random variable with a capital letter such as XX, YY, or ZZ. The amount of money a single student will spend on her statistics books is a random variable, and we represent it by XX.

Random variable

A random process or variable with a numerical outcome.

The possible outcomes of XX are labeled with a corresponding lower case letter xx and subscripts. For example, we write x1=$0x_1=\$0, x2=$137x_2=\$137, and x3=$170x_3=\$170, which occur with probabilities 0.200.20, 0.550.55, and 0.250.25. The distribution of XX is summarized in Figure 3.18 and Figure 3.19.

ii 1 2 3 Total
xix_i $0 $137 $170 –
P(X=xi)P(X=x_i) 0.20 0.55 0.25 1.00

Figure 3.19. The probability distribution for the random variable XX, representing the bookstore’s revenue from a single student.

We computed the average outcome of XX as $117.85 in Example 3.57. We call this average the expected value of XX, denoted by E(X)E(X). The expected value of a random variable is computed by adding each outcome weighted by its probability: E(X)=0×P(X=0)+137×P(X=137)+170×P(X=170)=0×0.20+137×0.55+170×0.25=117.85\begin{aligned} E(X) &= 0 \times P(X=0) + 137 \times P(X=137) + 170 \times P(X=170) \\ &= 0 \times 0.20 + 137 \times 0.55 + 170 \times 0.25 = 117.85 \end{aligned}

Expected value of a Discrete Random Variable

If XX takes outcomes x1x_1, ..., xkx_k with probabilities P(X=x1)P(X=x_1), ..., P(X=xk)P(X=x_k), the expected value of XX is the sum of each outcome multiplied by its corresponding probability: E(X)=x1×P(X=x1)+⋯+xk×P(X=xk)=∑i=1kxiP(X=xi)\begin{aligned} E(X) &= x_1 \times P(X = x_1) + \cdots + x_k\times P(X = x_k) \\ &= \sum_{i = 1}^{k} x_i P(X = x_i) \end{aligned} The Greek letter μ\mu may be used in place of the notation E(X)E(X).

The expected value for a random variable represents the average outcome. For example, E(X)=117.85E(X)=117.85 represents the average amount the bookstore expects to make from a single student, which we could also write as μ=117.85\mu=117.85.

It is also possible to compute the expected value of a continuous random variable (see Section 3.5). However, it requires a little calculus and we save it for a later class.2

In physics, the expectation holds the same meaning as the center of gravity. The distribution can be represented by a series of weights at each outcome, and the mean represents the balancing point. This is represented in Figures 3.18 and 3.20. The idea of a center of gravity also expands to continuous probability distributions. Figure 3.21 shows a continuous probability distribution balanced atop a wedge placed at the mean.

A bar is hung by a string, and three weights are hanging on the bar at three different locations. The weights are located at the locations 0, 137, and 170 and have weights proportional to the probabilities 0.2, 0.55, and 0.25, respectively. The weights are balanced, because the string that is suspending the bar is located at the mean of the distribution, 117.85.

Figure 3.20. A weight system representing the probability distribution for XX. The string holds the distribution at the mean to keep the system balanced.
A distribution that is skewed to the right is displayed, similar to how a histogram would appear if the bins were so small as to blend together and look continuous. This distribution is balancing atop a triangle located at the mean of the distribution.

Figure 3.21. A continuous distribution can also be balanced at its mean.

Variability in random variables

Suppose you ran the university bookstore. Besides how much revenue you expect to generate, you might also want to know the volatility (variability) in your revenue.

The variance and standard deviation can be used to describe the variability of a random variable. Section 2.1.4 introduced a method for finding the variance and standard deviation for a data set. We first computed deviations from the mean (xi−μx_i - \mu), squared those deviations, and took an average to get the variance. In the case of a random variable, we again compute squared deviations. However, we take their sum weighted by their corresponding probabilities, just like we did for the expectation. This weighted sum of squared deviations equals the variance, and we calculate the standard deviation by taking the square root of the variance, just as we did in Section 2.1.4.

General variance formula

If XX takes outcomes x1x_1, ..., xkx_k with probabilities P(X=x1)P(X=x_1), ..., P(X=xk)P(X=x_k) and expected value μ=E(X)\mu=E(X), then the variance of XX, denoted by Var(X)Var(X) or the symbol σ2\sigma^2, is σ2=(x1−μ)2×P(X=x1)+⋯⋯+(xk−μ)2×P(X=xk)=∑j=1k(xj−μ)2P(X=xj)\begin{aligned} \sigma^2 &= (x_1-\mu)^2\times P(X=x_1) + \cdots \\ & \qquad\quad\cdots+ (x_k-\mu)^2\times P(X=x_k) \\ &= \sum_{j=1}^{k} (x_j - \mu)^2 P(X=x_j) \end{aligned} The standard deviation of XX, labeled σ\sigma, is the square root of the variance.

Example 3.58

Compute the expected value, variance, and standard deviation of XX, the revenue of a single statistics student for the bookstore.


It is useful to construct a table that holds computations for each outcome separately, then add up the results.

ii 1 2 3 Total
xix_i $0 $137 $170
P(X=xi)P(X=x_i) 0.20 0.55 0.25
xi×P(X=xi)x_i \times P(X=x_i) 0 75.35 42.50 117.85

Thus, the expected value is μ=117.85\mu=117.85, which we computed earlier. The variance can be constructed by extending this table:

ii 1 2 3 Total
xix_i $0 $137 $170
P(X=xi)P(X=x_i) 0.20 0.55 0.25
xi×P(X=xi)x_i \times P(X=x_i) 0 75.35 42.50 117.85
xi−μx_i - \mu -117.85 19.15 52.15
(xi−μ)2(x_i-\mu)^2 13888.62 366.72 2719.62
(xi−μ)2×P(X=xi)(x_i-\mu)^2\times P(X=x_i) 2777.7 201.7 679.9 3659.3

The variance of XX is σ2=3659.3\sigma^2 = 3659.3, which means the standard deviation is σ=3659.3=$60.49\sigma = \sqrt{3659.3} = \$60.49.

Guided Practice 3.59

The bookstore also offers a chemistry textbook for $159 and a book supplement for $41. From past experience, they know about 25% of chemistry students just buy the textbook while 60% buy both the textbook and supplement.3

  1. What proportion of students don’t buy either book? Assume no students buy the supplement without the textbook.

  2. Let YY represent the revenue from a single student. Write out the probability distribution of YY, i.e. a table for each outcome and its associated probability.

  3. Compute the expected revenue from a single chemistry student.

  4. Find the standard deviation to describe the variability associated with the revenue from a single student.

Linear combinations of random variables

So far, we have thought of each variable as being a complete story in and of itself. Sometimes it is more appropriate to use a combination of variables. For instance, the amount of time a person spends commuting to work each week can be broken down into several daily commutes. Similarly, the total gain or loss in a stock portfolio is the sum of the gains and losses in its components.

Example 3.60

John travels to work five days a week. We will use X1X_1 to represent his travel time on Monday, X2X_2 to represent his travel time on Tuesday, and so on. Write an equation using X1X_1, ..., X5X_5 that represents his travel time for the week, denoted by WW.


His total weekly travel time is the sum of the five daily values: W=X1+X2+X3+X4+X5\begin{aligned} W = X_1 + X_2 + X_3 + X_4 + X_5 \end{aligned} Breaking the weekly travel time WW into pieces provides a framework for understanding each source of randomness and is useful for modeling WW.

Example 3.61

It takes John an average of 18 minutes each day to commute to work. What would you expect his average commute time to be for the week?


We were told that the average (i.e. expected value) of the commute time is 18 minutes per day: E(Xi)=18E(X_i) = 18. To get the expected time for the sum of the five days, we can add up the expected time for each individual day: E(W)=E(X1+X2+X3+X4+X5)=E(X1)+E(X2)+E(X3)+E(X4)+E(X5)=18+18+18+18+18=90 minutes\begin{aligned} E(W) &= E(X_1 + X_2 + X_3 + X_4 + X_5) \\ &= E(X_1) + E(X_2) + E(X_3) + E(X_4) + E(X_5) \\ &= 18 + 18 + 18 + 18 + 18 = 90\text{ minutes} \end{aligned} The expectation of the total time is equal to the sum of the expected individual times. More generally, the expectation of a sum of random variables is always the sum of the expectation for each random variable.

Guided Practice 3.62

Elena is selling a TV at a cash auction and also intends to buy a toaster oven in the auction. If XX represents the profit for selling the TV and YY represents the cost of the toaster oven, write an equation that represents the net change in Elena’s cash.4

Guided Practice 3.63

Based on past auctions, Elena figures she should expect to make about $175 on the TV and pay about $23 for the toaster oven. In total, how much should she expect to make or spend?5

Guided Practice 3.64

Would you be surprised if John’s weekly commute wasn’t exactly 90 minutes or if Elena didn’t make exactly $152? Explain.6

Two important concepts concerning combinations of random variables have so far been introduced. First, a final value can sometimes be described as the sum of its parts in an equation. Second, intuition suggests that putting the individual average values into this equation gives the average value we would expect in total. This second point needs clarification – it is guaranteed to be true in what are called linear combinations of random variables.

A linear combination of two random variables XX and YY is a fancy phrase to describe a combination aX+bY\begin{aligned} aX + bY \end{aligned} where aa and bb are some fixed and known numbers. For John’s commute time, there were five random variables – one for each work day – and each random variable could be written as having a fixed coefficient of 1: 1X1+1X2+1X3+1X4+1X5\begin{aligned} 1X_1 + 1 X_2 + 1 X_3 + 1 X_4 + 1 X_5 \end{aligned} For Elena’s net gain or loss, the XX random variable had a coefficient of +1 and the YY random variable had a coefficient of -1.

When considering the average of a linear combination of random variables, it is safe to plug in the mean of each random variable and then compute the final result. For a few examples of nonlinear combinations of random variables – cases where we cannot simply plug in the means – see the footnote.7

Linear combinations of random variables and the average result

If XX and YY are random variables, then a linear combination of the random variables is given by aX+bY\begin{aligned} aX + bY \end{aligned} where aa and bb are some fixed numbers. To compute the average value of a linear combination of random variables, plug in the average of each individual random variable and compute the result: a×E(X)+b×E(Y)\begin{aligned} a\times E(X) + b\times E(Y) \end{aligned} Recall that the expected value is the same as the mean, e.g. E(X)=μXE(X) = \mu_X.

Example 3.65

Leonard has invested $6000 in Caterpillar Inc (stock ticker: CAT) and $2000 in Exxon Mobil Corp (XOM). If XX represents the change in Caterpillar’s stock next month and YY represents the change in Exxon Mobil’s stock next month, write an equation that describes how much money will be made or lost in Leonard’s stocks for the month.


For simplicity, we will suppose XX and YY are not in percents but are in decimal form (e.g. if Caterpillar’s stock increases 1%, then X=0.01X=0.01; or if it loses 1%, then X=−0.01X=-0.01). Then we can write an equation for Leonard’s gain as $6000×X+$2000×Y\begin{aligned} \$6000\times X + \$2000\times Y \end{aligned} If we plug in the change in the stock value for XX and YY, this equation gives the change in value of Leonard’s stock portfolio for the month. A positive value represents a gain, and a negative value represents a loss.

Guided Practice 3.66

Caterpillar stock has recently been rising at 2.0% and Exxon Mobil’s at 0.2% per month, respectively. Compute the expected change in Leonard’s stock portfolio for next month.8

Guided Practice 3.67

You should have found that Leonard expects a positive gain in Guided Practice 3.66. However, would you be surprised if he actually had a loss this month?9

Variability in linear combinations of random variables

Quantifying the average outcome from a linear combination of random variables is helpful, but it is also important to have some sense of the uncertainty associated with the total outcome of that combination of random variables. The expected net gain or loss of Leonard’s stock portfolio was considered in Guided Practice 3.66. However, there was no quantitative discussion of the volatility of this portfolio. For instance, while the average monthly gain might be about $124 according to the data, that gain is not guaranteed. Figure 3.22 shows the monthly changes in a portfolio like Leonard’s during a three year period. The gains and losses vary widely, and quantifying these fluctuations is important when investing in stocks.

A dot plot is overlaid on a box plot for a variable "Monthly Returns Over 3 Years". The box portion spans about -200 to 450, with the median line at about 200. The whiskers extend to the lower end at about -600 and at the upper end at about 1050. There is one point beyond the lower whisker located at about -1400. The the dot plot, the points are pretty evenly distributed across the locations of the box-and-whiskers portion of the box plot, with the one exception being the point at -1400.

Figure 3.22. The change in a portfolio like Leonard’s for 36 months, where $6000 is in Caterpillar’s stock and $2000 is in Exxon Mobil’s.

Just as we have done in many previous cases, we use the variance and standard deviation to describe the uncertainty associated with Leonard’s monthly returns. To do so, the variances of each stock’s monthly return will be useful, and these are shown in Figure 3.23. The stocks’ returns are nearly independent.

Mean (xˉ\bar{x}) Standard deviation (ss) Variance (s2s^2)
CAT 0.0204 0.0757 0.0057
XOM 0.0025 0.0455 0.0021

Figure 3.23. The mean, standard deviation, and variance of the CAT and XOM stocks. These statistics were estimated from historical stock data, so notation used for sample statistics has been used.

Here we use an equation from probability theory to describe the uncertainty of Leonard’s monthly returns; we leave the proof of this method to a dedicated probability course. The variance of a linear combination of random variables can be computed by plugging in the variances of the individual random variables and squaring the coefficients of the random variables: Var(aX+bY)=a2×Var(X)+b2×Var(Y)\begin{aligned} Var(aX + bY) = a^2\times Var(X) + b^2\times Var(Y) \end{aligned} It is important to note that this equality assumes the random variables are independent; if independence doesn’t hold, then a modification to this equation would be required that we leave as a topic for a future course to cover. This equation can be used to compute the variance of Leonard’s monthly return: Var(6000×X+2000×Y)=60002×Var(X)+20002×Var(Y)=36,000,000×0.0057+4,000,000×0.0021≈213,600\begin{aligned} Var(6000\times X + 2000\times Y) &= 6000^2\times Var(X) + 2000^2\times Var(Y) \\ &= 36,000,000\times 0.0057 + 4,000,000\times 0.0021 \\ &\approx 213,600 \end{aligned} The standard deviation is computed as the square root of the variance: 213,600=$463\sqrt{213,600} = \$463. While an average monthly return of $124 on an $8000 investment is nothing to scoff at, the monthly returns are so volatile that Leonard should not expect this income to be very stable.

Variability of linear combinations of random variables

The variance of a linear combination of random variables may be computed by squaring the constants, substituting in the variances for the random variables, and computing the result: Var(aX+bY)=a2×Var(X)+b2×Var(Y)\begin{aligned} Var(aX + bY) = a^2\times Var(X) + b^2\times Var(Y) \end{aligned} This equation is valid as long as the random variables are independent of each other. The standard deviation of the linear combination may be found by taking the square root of the variance.

Example 3.68

Suppose John’s daily commute has a standard deviation of 4 minutes. What is the uncertainty in his total commute time for the week?


The expression for John’s commute time was X1+X2+X3+X4+X5\begin{aligned} X_1 + X_2 + X_3 + X_4 + X_5 \end{aligned} Each coefficient is 1, and the variance of each day’s time is 42=164^2=16. Thus, the variance of the total weekly commute time is variance =12×16+12×16+12×16+12×16+12×16=5×16=80standard deviation =variance=80=8.94\begin{aligned} &\text{variance }= 1^2 \times 16 + 1^2 \times 16 + 1^2 \times 16 + 1^2 \times 16 + 1^2 \times 16 = 5\times 16 = 80 \\ &\text{standard deviation } = \sqrt{\text{variance}} = \sqrt{80} = 8.94 \end{aligned} The standard deviation for John’s weekly work commute time is about 9 minutes.

Guided Practice 3.69

The computation in Example 3.68 relied on an important assumption: the commute time for each day is independent of the time on other days of that week. Do you think this is valid? Explain.10

Guided Practice 3.70

Consider Elena’s two auctions from Guided Practice 3.62 in Section 3.4. Suppose these auctions are approximately independent and the variability in auction prices associated with the TV and toaster oven can be described using standard deviations of $25 and $8. Compute the standard deviation of Elena’s net gain.11

Consider again Guided Practice 3.70. The negative coefficient for YY in the linear combination was eliminated when we squared the coefficients. This generally holds true: negatives in a linear combination will have no impact on the variability computed for a linear combination, but they do impact the expected value computations.

Exercises

Exercise 3.29

College smokers. At a university, 13% of students smoke.

  1. Calculate the expected number of smokers in a random sample of 100 students from this university.

  2. The university gym opens at 9 am on Saturday mornings. One Saturday morning at 8:55 am there are 27 students outside the gym waiting for it to open. Should you use the same approach from part (a) to calculate the expected number of smokers among these 27 students?

Exercise 3.30

Ace of clubs wins. Consider the following card game with a well-shuffled deck of cards. If you draw a red card, you win nothing. If you get a spade, you win $5. For any club, you win $10 plus an extra $20 for the ace of clubs.

  1. Create a probability model for the amount you win at this game. Also, find the expected winnings for a single game and the standard deviation of the winnings.

  2. What is the maximum amount you would be willing to pay to play this game? Explain your reasoning.

Exercise 3.31

Hearts win. In a new card game, you start with a well-shuffled full deck and draw 3 cards without replacement. If you draw 3 hearts, you win $50. If you draw 3 black cards, you win $25. For any other draws, you win nothing.

  1. Create a probability model for the amount you win at this game, and find the expected winnings. Also compute the standard deviation of this distribution.

  2. If the game costs $5 to play, what would be the expected value and standard deviation of the net profit (or loss)? (Hint: profit = winnings −- cost; X−5X-5)

  3. If the game costs $5 to play, should you play this game? Explain.

Exercise 3.32

Is it worth it? Andy is always looking for ways to make money fast. Lately, he has been trying to make money by gambling. Here is the game he is considering playing: The game costs $2 to play. He draws a card from a deck. If he gets a number card (2-10), he wins nothing. For any face card ( jack, queen or king), he wins $3. For any ace, he wins $5, and he wins an extra $20 if he draws the ace of clubs.

  1. Create a probability model and find Andy’s expected profit per game.

  2. Would you recommend this game to Andy as a good way to make money? Explain.

Exercise 3.33

Portfolio return. A portfolio’s value increases by 18% during a financial boom and by 9% during normal times. It decreases by 12% during a recession. What is the expected return on this portfolio if each scenario is equally likely?

Exercise 3.34

Baggage fees. An airline charges the following baggage fees: $25 for the first bag and $35 for the second. Suppose 54% of passengers have no checked luggage, 34% have one piece of checked luggage and 12% have two pieces. We suppose a negligible portion of people check more than two bags.

  1. Build a probability model, compute the average revenue per passenger, and compute the corresponding standard deviation.

  2. About how much revenue should the airline expect for a flight of 120 passengers? With what standard deviation? Note any assumptions you make and if you think they are justified.

Exercise 3.35

American roulette. The game of American roulette involves spinning a wheel with 38 slots: 18 red, 18 black, and 2 green. A ball is spun onto the wheel and will eventually land in a slot, where each slot has an equal chance of capturing the ball. Gamblers can place bets on red or black. If the ball lands on their color, they double their money. If it lands on another color, they lose their money. Suppose you bet $1 on red. What’s the expected value and standard deviation of your winnings?

Exercise 3.36

European roulette. The game of European roulette involves spinning a wheel with 37 slots: 18 red, 18 black, and 1 green. A ball is spun onto the wheel and will eventually land in a slot, where each slot has an equal chance of capturing the ball. Gamblers can place bets on red or black. If the ball lands on their color, they double their money. If it lands on another color, they lose their money.

  1. Suppose you play roulette and bet $3 on a single round. What is the expected value and standard deviation of your total winnings?

  2. Suppose you bet $1 in three different rounds. What is the expected value and standard deviation of your total winnings?

  3. How do your answers to parts (a) and (b) compare? What does this say about the riskiness of the two games?

Notes

  1. If they sell a little more or a little less, this should not be a surprise. Hopefully Chapter 1 helped make clear that there is natural variability in observed data. For example, if we would flip a coin 100 times, it will not usually come up heads exactly half the time, but it will probably be close. ↩

  2. μ=∫xf(x)dx\mu = \int xf(x)dx where f(x)f(x) represents a function for the density curve. ↩

  3. (a) 100% - 25% - 60% = 15% of students do not buy any books for the class. Part (b) is represented by the first two lines in the table below. The expectation for part (c) is given as the total on the line yi×P(Y=yi)y_i\times P(Y=y_i). The result of part (d) is the square-root of the variance listed on in the total on the last line: σ=Var(Y)=$69.28\sigma = \sqrt{Var(Y)} = \$69.28.

    ii (scenario) 1 (noBook) 2 (textbook) 3 (both) Total
    yiy_i 0.00 159.00 200.00
    P(Y=yi)P(Y=y_i) 0.15 0.25 0.60
    yi×P(Y=yi)y_i\times P(Y=y_i) 0.00 39.75 120.00 E(Y)=159.75E(Y) = 159.75
    yi−E(Y)y_i-E(Y) -159.75 -0.75 40.25
    (yi−E(Y))2(y_i-E(Y))^2 25520.06 0.56 1620.06
    (yi−E(Y))2×P(Y)(y_i-E(Y))^2\times P(Y) 3828.0 0.1 972.0 Var(Y)≈4800Var(Y) \approx 4800
    ↩
  4. She will make XX dollars on the TV but spend YY dollars on the toaster oven: X−YX-Y. ↩

  5. E(X−Y)=E(X)−E(Y)=175−23=$152E(X-Y) = E(X) - E(Y) = 175 - 23 = \$152. She should expect to make about $152. ↩

  6. No, since there is probably some variability. For example, the traffic will vary from one day to next, and auction prices will vary depending on the quality of the merchandise and the interest of the attendees. ↩

  7. If XX and YY are random variables, consider the following combinations: X1+YX^{1+Y}, X×YX\times Y, X/YX/Y. In such cases, plugging in the average value for each random variable and computing the result will not generally lead to an accurate average value for the end result. ↩

  8. E($6000×X+$2000×Y)=$6000×0.020+$2000×0.002=$124E(\$6000\times X + \$2000\times Y) = \$6000\times 0.020 + \$2000\times 0.002 = \$124. ↩

  9. No. While stocks tend to rise over time, they are often volatile in the short term. ↩

  10. One concern is whether traffic patterns tend to have a weekly cycle (e.g. Fridays may be worse than other days). If that is the case, and John drives, then the assumption is probably not reasonable. However, if John walks to work, then his commute is probably not affected by any weekly traffic cycle. ↩

  11. The equation for Elena can be written as (1)×X+(−1)×Y\begin{aligned} (1)\times X + (-1)\times Y \end{aligned} The variances of XX and YY are 625 and 64. We square the coefficients and plug in the variances: (1)2×Var(X)+(−1)2×Var(Y)=1×625+1×64=689\begin{aligned} (1)^2\times Var(X) + (-1)^2\times Var(Y) = 1\times 625 + 1\times 64 = 689 \end{aligned} The variance of the linear combination is 689, and the standard deviation is the square root of 689: about $26.25. ↩

Credit and licence

“3.4 Random variables” is from OpenIntro Statistics, Fourth Edition, by David M Diez, Mine Çetinkaya-Rundel and Christopher D Barr, shared under a CC BY-SA 3.0 license. WorldClass Statistics is a derivative of OpenIntro Statistics, shared under the same license; the original book may be found at openintro.org/book/os.

Source: https://www.openintro.org/book/os/

Licence: CC BY-SA 3.0 (creativecommons.org/licenses/by-sa/3.0/). You may share and adapt it under the same licence, with this credit. WorldClass adapted the formatting only: the text is the authors', with interactive parts and links to other sites left out.

Build status · Flash Infinity AI™ is a trademark of AI-Flash Inc.. WorldClass is not affiliated with, approved or accredited by any exam board, curriculum provider or university unless a page says so.