yego.me
💡 Stop wasting time. Read Youtube instead of watch. Download Chrome Extension

Variance and standard deviation of a discrete random variable | AP Statistics | Khan Academy


4m read
·Nov 11, 2024

In a previous video, we defined this random variable (X). It's a discrete random variable; it can only take on a finite number of values. I defined it as the number of workouts I might do in a week. We calculated the expected value of our random variable (X), which you could also denote as the mean of (X), and we use the Greek letter (\mu), which we use for population mean. All we did is take the probability-weighted sum of the various outcomes, and we got for this random variable with this probability distribution, we got an expected value or a mean of 2.1.

What we're going to do now is extend this idea to measuring spread, and so we're going to think about what the variance of this random variable is. Then, we could take the square root of that to find out what the standard deviation is. The way we are going to do this has parallels with the way we've calculated variance in the past.

So, the variance of our random variable (X): what we're going to do is take the difference between each outcome and the mean, square that difference, and then we're going to multiply it by the probability of that outcome. For example, for this first data point, you're going to have (0 - 2.1) squared times the probability of getting (0) time (0.1). Then you are going to get (+) (1 - 2.1) squared times the probability that you get (1) times (0.15). Then you're going to get (+) (2 - 2.1) squared times the probability that you get a (2) times (0.4). Then you have (+) (3 - 2.1) squared times (0.25), and then last but not least you have (+) (4 - 2.1) squared times (0.1).

So, once again, the difference between each outcome and the mean, we square it, and we multiply it times the probability of that outcome. This is going to be (-2.1) squared, which is just (2.1) squared, so I'll just write this as (2.1) squared times (0.1); that's the first term. Then we're going to have (+) (1 - 2.1) is (-1.1) and then we're going to square that, so that's just going to be the same thing as (1.1) squared, which is (1.21), but I'll just write it out as (1.1) squared times (0.15).

Then this is going to be (2) minus (2.1) is (0.1). When you square it, it's going to be equal to (+) (0.1); if you have (0.1) times (0.4), that’s (0.01) times (0.4). Then, plus, this is going to be (0.9) squared, so that is (0.81) times (0.25). Then we're almost there; this is going to be (+) (1.9) squared times (0.1), and we get (1.19).

So this is all going to be equal to (1.19), and if we want to get the standard deviation for this random variable, we would denote that with the Greek letter (\sigma). The standard deviation for the random variable (X) is going to be equal to the square root of the variance, the square root of (1.19), which is equal to... let's just get the calculator back here.

So we are just going to take the square root of what we just calculated; I'll just type it again: (1.19), and that gives us approximately (1.09); approximately (1.09).

So, let's see if this makes sense. Let me put this all on a number line right over here. So you have the outcome (0), (1), (2), (3), and (4). You have a (10%) chance of getting a zero, so I will draw that like this. Let's just say this is a height of (10%).

You have a (15%) chance of getting one, so that will be one and a half times higher, so it looks something like this. You have a (40%) chance of getting a (2), so that's going to be like this. You get a (40%) chance of getting a (2). You have a (25%) chance of getting a (3), so it looks like this. And then you have a (10%) chance of getting a (4), so it looks like that.

So this is a visualization of this discrete probability distribution where I didn't draw the vertical axis here, but this would be (0.1), this would be (0.15), this is (0.25), and that is (0.05). Then we see that the mean is at (2.1). The mean is at (2.1), which makes sense.

Even though this random variable only takes on integer values, you can have a mean that takes on a non-integer value. Then the standard deviation is (1.09), so (1.09) above the mean is going to get us close to (3.2), and (1.09) below the mean is going to get us close to (1).

So this all, at least intuitively, feels reasonable. This mean does seem to be indicative of the central tendency of this distribution, and the standard deviation does seem to be a decent measure of the spread.

More Articles

View All
Having no charisma is ruining your life
Due to the internet age and people being on their phones all the time, people have lost the ability to communicate effectively with other people. And that’s probably not a secret to you at all. You’ve probably felt the effects of this in your own life. Th…
Integral of product of cosines
We’ve been doing several videos now to establish a bunch of truths of definite integrals of various combinations of trigonometric functions so that we will have a really strong mathematical basis for actually finding the Fourier coefficients. I think we o…
Military Father | No Man Left Behind
My task was to take out one of the most high-value strategic command and control targets in Belgrade, the capital city of the former Republic of Yugoslavia. I felt absolutely totally confident that I was as well trained and well prepared as possible for a…
How Your Eyes Make Sense of the World | Decoder
When you look at this painting, what do you see? A woman looking out a window? How about now? This famous painting by Salvador Dali is based on something called the “Lincoln illusion.” The effect shows how blurring pixelated images can make it easier to r…
Mentoring New Photographers | Sea of Hope: America's Underwater Treasures
So, is lighting the whole secret down there? Yeah, I think one of the best things, um, to do underwater is to sort of meter for the background, the ambient, and then maybe underexpose that just a little bit. It kind of creates a nice, richly saturated bac…
It’s Here: The Reverse Housing Crash Of 2024
What’s up Graham, it’s guys here and in a weird twist of events, home prices are crashing higher. That’s right! Despite 8% mortgage rates, record low affordability, and home sales on pace for the worst year since 1993, home prices have managed to hit a br…