So now, we've set up our testing for one population proportion, and now we're actually going to test it by calculating a test statistic, and then getting a p-value and finally, making a conclusion of that p-value. So, just to reiterate, we set up our hypothesis to be a null hypothesis p, equaling 0.52, alternative hypothesis being p greater than 0.52, because we wanted to see if there's a significant increase, and this is where p is the population proportion of parents with a teenager who believe that electronics and social media, is the cause of their teenager's lack of sleep. And the last step we wanted to select a alpha, of significance level, which typically is going to be 0.05, and we'll use that as one of the last steps and the hypothesis tests to make our conclusion. And from the poll we have the best estimate of p, which is p-hat, to be 0.56 of a sample size of 1,018. So, we've now got our hypothesis, we check those assumptions and now, we're going to calculate a test statistic, which a test statistic that is determined by taking our best estimate, subtracting the hypothesized estimate, and dividing by the standard error of the estimate. So, for our case of a one proportion test, we're going to have something that looks like this, p-hat minus p-naught, divided by the standard error. So, we know p-hat is 0.56, p-naught again was that, under the null hypothesis, what we believe p to be, and so that's 0.52, and then we have the standard error. So, here the standard error you might want to write it like so, standard error of p-hat is equal to the square root of p times one minus p, divided by n. But again, we don't exactly know what p is, but we have a pretty good guess, and that guess is p-naught, and so really this standard error should be written as, standard error of p-hat is equal to the square root of p-naught, times one minus p-naught, divide by n. So, what this is, we call this the null standard error. So, under the null hypothesis, we have this standard error for our p-hat. Using these two equations, p-hat minus p-naught, divided by its standard error, and we know what our null standard error is, we can calculate our test statistic. So, putting everything in, 0.56 minus 0.52, divided by the standard error which happened to be 0.0157, we get a Z test statistic of 2.555. And so this test statistic, I call it a Z test statistic because we are under a normal distribution, and so whenever we have proportions, it's going to follow a normal distribution, again as long as our sample size is large enough. What does this Z test statistic really mean though? Interpreting it, we could say this Z test statistic means that our observed sample proportion is, 2.555 null standard errors above our hypothesized population proportion, and so we took our sample, we subtracted out the hypothesis, and then divided by the standard error, so we get the number of null standard errors. So, let's talk a little bit more about this test statistic, the Z test statistic, is just another type of random variable. It has its own distribution. That distribution is going to follow a normal zero,one, and the reasoning why it's normal zero,one, is our original data was normal, and now we've just centered and scaled that original data. And so what that looks like, is if we have our equation here, the numerator is what's centering our data, we're subtracting out the hypothesized mean, and then the one we divide by the standard error, we are scaling our data and so, we go from some normal distribution and then we are just manipulating it, to become a normal zero,one, and then that is the distribution at the Z test statistic follows. So, now that we have the Z test statistic, we can find a p-value from it, and so here I have a normal zero,one curve, so I could mark in the center zero, and then one standard error would be equal to one, so I can mark out, a one here, a two and a three, out there. So, we have a Z test statistic again of 2.55, and we want to find our p-value from that. So, on this chart I'm going to put a big line, where 2.55 approximately is about, and if you recall our Ha, was p greater than 0.52. So this greater sign here, it's very important because that tells me, I want all the values that are greater than my test statistic. So, if I shade in this area to the right of where I drew that big vertical line, this shaded area will be my p-value, and to get that p-value, you either have to plug it into a programming language like Python or you can go and look it up in what's called the Z-table, and so here if I looked up the value of 2.55 Z test statistic, I would get 0.0053 as my p-value. Now, that we have our p-value, we can come up with a conclusion with it. So, we have a p-value 0.0053, and we noticed that's less than alpha we said earlier in the hypothesis. So because it's less than our alpha of 0.05, that means we will reject the null hypothesis, that p equals 0.52. So, basically we got a result that was very unlikely to occur. So, now our initial assumption, we're starting to not really believe it quite as much. And now that we've said we're going to reject the null, we just want to provide one summary conclusion statement, and that would be something that looks like this. There is sufficient evidence to conclude that the population proportion of parents with a teenager who believe that electronics and social media is the cause for lack of sleep is greater than 0.5, or greater than 52 percent. So, here it's kind of summing everything up, we got our p-value, we either reject or we fail to reject. So, failing to reject is when we have a p-value being greater than our alpha, and then we have a conclusion statement based of that, either rejection or failing to reject. And that is the end of your first hypothesis tests, and again this is all for one proportion, so in future tests there'll be a little bit different. Some of the assumptions might be different, the hypotheses will be different, the test statistic is always going to follow that same form, but it will just slightly change the values that you need to put in. So, to summarize what we've talked about in this example of a hypothesis test, we learned that there are four main steps. So we state our hypothesis and select a significance level, which is alpha, we check our assumptions, we then calculate a test statistic, and we get a p-value from that test statistic, and finally we draw a conclusion from that p-value. In addition to this, we also talked a little bit more about the Z test statistic distribution, and how it's a normal zero,one, because we centered and scaled our initial distribution which was also normal. In future cases you aren't always going to have a Z test statistic, we'll see other ones like the T test statistic, in future lectures.