Z- Test
A Z-test is a hypothesis test based on the Z-statistic, which follows the standard normal distribution under the null hypothesis. Z-test is used if
-
Sample size is greater than 30.
-
Data points are independent of each other, i.e. one data point is not related or does not affect another data point.
-
Data is randomly selected from a population, where each item has an equal chance of being selected.
Test statistic/ Z-test = (sample statistic) - (value of parameter according to null hypothesis)
(Standard error of sample statistic)
Example
Consider the size (diameter) of a ball to be 30 cm in a production process. A sample of 400 balls is taken and the mean diameter is found to be 28 cm with a standard deviation of 2 cm. With a 95% confidence interval, find out whether the production process is efficient.
Hypothesis:
H0: Mean diameter of the population = 30
H1: Mean diameter of the population 30
Test statistic
Z statistic = (28-30)/2 = -1
P value
P(z>=-1) = 0.1586 >= 0.05 (for 95% confidence interval)
Interpretation
Hence, null hypothesis cannot be rejected and so, production process is correct.