Hypothesis Testing in Statistics The 2-Tailed Z-Test

Now that we have been introduced to some of the basic terms that we need to know relating to hypothesis testing in statistics, let's look at an example where we can put this knowledge to good use. We will look at an example in statistics where we have an established null hypothesis and alternate hypothesis, and we will run a statistical test to determine whether we should reject the null hypothesis or fail to reject the null hypothesis based on the data gathered from a sample of the population. Here is the example problem that I would like to demonstrate for you.

Example: The average IQ for the adult population is 100 with a standard deviation of 15. A researcher believes this value has changed. The researcher decides to run an IQ test on 75 adults to test his theory. The average IQ of the sample taken was found to be 105. Is there enough evidence to suggest that the average IQ has changed?

So, first, let's state what the null and alternative hypotheses are for this problem. It is currently believed that the average IQ of the adult population is 100. This is our null hypothesis. Therefore, the alternative hypothesis for this problem is that the average IQ has changed but we don't know if it has gone down or gone up only that it is no longer 100. We can write both of these like this:

Since we are unsure in which direction we think the IQ has changed, then we need to perform what is referred to as a 2-tailed test, which I will explain later in this article. For now, assume that we must perform the 2-tailed statistical test as opposed to a 1-tailed test.

The next step in the process is to decide on and choose a level of confidence that we would like to have when making your decision to either reject the null hypothesis or to fail to reject this hypothesis. Since this level of confidence is not stated in our problem, we can assume the default standard level of confidence, denoted by the Greek letter alpha, a, and set a = 0.05. The graph of our normal distribution (bell curve) with a = 0.05 (2-tailed, since we only suspect the average IQ score has changed but don't know if it is less or greater) will look like the following:

The area under the curve on the left shown in red is 0.025 and on the right also shown in red is 0.025 which adds up to a total area equivalent to a = 0.05. This implies that the confidence level for our example is 1 - a = 0.95 which is represented by the white area under the normal distribution curve in the diagram above.

The next step in the process is to determine the critical values for the problem. In this example, we can use either a z-score or a t-value in calculating the critical values. However, in statistics, if the standard deviation is a given (or is known), then we will always use the z-score for the test. Here in this example problem, we are told that the population standard deviation is 15, so we will use the z-test instead of the t-test when computing the critical values for the problem. The standard deviation in statistics is denoted by the Greek letter for sigma and looks like the following:

Now, to determine the critical values called c.v. in statistics, this is the area in the graph above that separates the red region from the rest of the curve. If we go to a z-table reference found in any statistical CRC reference book, we can see that in this table shown below:

a 95% confidence level will give us the area under one tail of the curve in a 2-tail test of 0.025 (which we already knew) and if we look under the z-score column, we see that the corresponding z-score = 1.960. The area in red in the normal distribution graph above is what is referred to as our rejection region. Therefore, the critical values we have determined from the z-table are 1.960 and - 1.960 since this is a 2-tailed test. What we need to determine next is the test statistic that we're going to use to perform our test. As stated earlier, since the standard deviation of 15 is given, we will use the default z-test to determine the value of z that we obtain from our data. The formula for z is shown below:

In this formula, X-bar is our sample mean from the data that we collected. The researcher gathered data from 75 adults (our sample) and determined the mean of that sample to be 105. So, X-bar = 105. The value of mu (Greek letter for the population mean) was given as 100. In the denominator of the equation the value of sigma (Greek letter corresponding to the standard deviation) is equal to 15 as stated in the problem. And finally, the value of n is the sample size which is equivalent to 75, also given in the problem. When we perform this calculation for Z we obtain:

The Z-value derived in the above calculation is rounded to 2 decimal places which gives us a value of Z = 2.89. This value is referred to as the test statistic. So, how can we use this test statistic to determine whether we should reject the null hypothesis or to fail to reject the null hypothesis? The answer to this question lies in knowing the boundaries for the critical values we determined from our z-table above which were shown to be - 1.960 and 1.960, respectively. Since the value of Z we calculated using our statistics formula for Z was 2.89, and 2.89 > 1.960, we can say that its value lies inside the critical value region of -1.960 and 1.960 on either tail of the graph which means that it lies within the rejection region depicted in red in the graph. Therefore, we can conclude that we should reject the null hypothesis, H0, and in doing so, we can accept our alternative hypothesis, HA. By rejecting our null hypothesis we are not saying that the alternative hypothesis is necessarily True, but we can say that we accept it as the most statistically viable choice.

Therefore, in conclusion, the original problem asked us "Is there enough evidence to suggest that the average IQ has changed?" Since we have rejected our null hypothesis, we can say with a confidence level of 95% that the answer to the question is "Yes", the average IQ has changed.

Keep watching my blog because in the next blog article, I will demonstrate the use of a 1-tailed t-test as the test statistic to use instead of the z-test that we used in this example problem