If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

# Variance of a binomial variable

AP.STATS:
UNC‑3 (EU)
,
UNC‑3.C (LO)
,
UNC‑3.C.1 (EK)

## Video transcript

what we're going to do in this video is continue our journey trying to understand what the expected value and what the variance of a binomial variable is going to be or what a what the expected value or the variance of a binomial distribution is going to be which is just the distribution distribution of a binomial variable and so like in the last video I have this binomial variable X that's defined in a very general sense it's the number of successes from n trials so it's a finite number of trials where the probability of success is equal to P so the probability is constant across the trials for each of these independent trials so the probability of success in one trial is not dependent on what happened in the other trials and we also talked in that previous video where we talked about the expected value of this binomial variable is we said hey it could be viewed that this binomial variable can be viewed as the sum of n of what you could really consider to be a Bernoulli variable here so this variable this random variable Y the probability that's equal to 1 you could view that as a success is equal to P the probability that it's a failure that Y is equal to 0 is 1 minus P so you could view why the outcome of Y is really the or whether Y is 1 or 0 is really whether we had a success or not in each of these trials so if you add up and Y's then you are going to get X and we use that information to figure out what the expected value of X is going to be because the expected value of y is pretty straightforward to directly compute expected value of y it's just probability weighted outcomes so it's P times 1 plus 1 minus P 1 minus P times 0 times 0 this whole term is going to be 0 and so the expected value of y is really just P and so if you said the expected value of x well that's just going to be we could let me just write it over here this is all review we could say that the expected value of x is just going to be equal to we know from our expected value properties that's going to be equal to the sum of the expected values of these and or you could say it is n times the expected value times the expected value of y the expected value of y is P so this is going to be equal to n times P now we're going to do the same idea to figure out what the variance of X is going to be equal to because we could see we know Farmar variance properties you can't do this with standard deviation but you could do it with variance and then once you figure out the variance you just take the square root for the standard deviation the variance of X is similarly going to be the sum of the variances of these endwise so it's going to be similarly n times the variance n times the variance of Y so this all boils down to what is the variance of Y going to be equal to so let me scroll over a little bit get a little bit of more real estate and I will figure that out right over right over here all right so we want to figure out the variance of Y so variance of Y is going to be equal to what well here it's going to be the probability squared distances from the expected value so we have a probability of P where what is going to be our squared distance from the expected value well we have we're going to get a 1 with a probability of P so in that case our distance from the mean or from the expected value we're at 1 the expected value we already know is equal to P so that's that for that possible outcome the squared distance times its probability weight and then we have actually let me scroll over a little I'll just do it right over here plus we have a probability of 1 minus P 1 minus P for the other possible outcome so in that outcome we are at 0 and the difference between 0 and our expected value well that's just going to be 0 minus P and once again we are going to square that distance and so this is the expression or the scale square that quantity and so this is expression for the variance of Y and we can simplify a little bit so this is all going to be equal to so let me just P times 1 minus P squared and then this is just going to be P squared times 1 minus P plus P squared times 1 minus P and let's see we can factor out a P times 1 minus P so what is that going to be left with so if we factor out a P times 1 minus P here we're just going to be left with a 1 minus P and if we factor out a P times 1 minus P here we're just going to have a plus P these two cancel out this is just this whole thing is just a 1 so you're left with P times 1 minus P which is indeed the variance for binomial variable we actually prove that in other videos like I said doesn't hurt to see it again but there you have it we know what the variance of Y is it is P times 1 minus P and the variance of X is just n times the variance of Y so there we go we deserve a little bit of a drumroll the variance of X is equal to n times P times 1 minus P so if we were to take the concrete example of the last video where if I were to take 10 free throws so each trial is a shot is a free throw so if I were to take 10 free throws and my probability of success is 0.3 I have a 30 percent free throw percentage the variance that I would expect to see so in that case the variance if X is the number of free throws I make after these ten shots my variance will be 10 times 0.3 0.3 times 1 minus 0.3 so 0.7 and so that would be what this right over here so this would be equal to 10 times 0.3 times 0.7 it times 0.2 1 so my variance in this situation is going to be equal to two point one it is equal to to point one and if I wanted to figure out the standard deviation of this right over here I would just take the square root of this so that's what the standard deviation just take the square root of this expression right over here
AP® is a registered trademark of the College Board, which has not reviewed this resource.