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.

# Simulation showing value of t statistic

AP.STATS:
UNC‑4 (EU)
,
UNC‑4.O (LO)
,
UNC‑4.O.1 (EK)
,
VAR‑7 (EU)
,
VAR‑7.A (LO)
,
VAR‑7.A.1 (EK)

## Video transcript

in a previous video we talked about trying to estimate a population mean with a sample mean and then constructing a confidence interval about that sample mean and we talked about different scenarios we could use Z table plus the true population standard deviation and that actually would construct pretty valid confidence intervals but the problem is you don't know the population standard deviation and so you might try to use a Z table to find your critical values plus the sample standard deviation but what we talked about is that this doesn't actually do a good job of calculating our confidence intervals and we're going to see that experimentally in a few seconds and so instead we have something called a t statistic where if we want our critical value we use a t table instead of a Z table and then we use that in conjunction with our sample standard deviation and then all of a sudden we are actually going to have pretty good confidence intervals to make this a little bit more real let's look at a simulation so this is a scratch pad on Khan Academy made by Khan Academy user charlotte allen and the whole point there is to see what our confidence intervals look like with these different scenarios so let's say we have a true population mean of 2.0 for some let's say it's the average number the mean number of apples people eat a day the true population mean is 2 that seems high but maybe it's in a certain country that has a lot of apples and let's say we know that the population standard deviation is 0.5 and we're going to create confidence intervals with the goal of having a 95% confidence level and we're going to take sample sizes of 12 so first we can construct our confidence intervals using Z and Sigma which is a legitimate way to do it and so let's just draw a bunch of samples here and so we do see that it looks like it is roughly 95% when we keep making these samples and constructing these confidence intervals that 95% of the time these confidence intervals contain our true population mean so these look like a good confidence intervals but what we've talked about is normally when you're doing this type of thing this type of inferential statistics you don't know the population standard deviation you don't know Sigma so in said we off you might be tempted to use Z with our sample standard deviations but if you look at that for these exact same samples we just calculated notice now when we did it over and over again we've done this 625 times in this scenario where we keep calculating the confidence intervals with Z and s the true population mean is contained in the intervals only ninety two point two percent of the time and we could keep going so if we have a much lower hit rate than we would hope to have if we were actually using Z and Sigma now what's neat is if we use T use a T's table notice this is getting much closer and this is neat because with the T table and something that we can actually get from the sample the sample standard deviation we're actually getting able to have a pretty close hit rate to what we would have if we actually knew the population standard deviation so that's the value of T and T statistics and we're going to give more and more examples including using a T table in future videos
AP® is a registered trademark of the College Board, which has not reviewed this resource.