The Z.TEST function in Google Sheets is a powerful statistical tool used to determine the probability of obtaining a particular Z-score under the assumption of a standard normal distribution. It is particularly useful in hypothesis testing, where you may want to assess whether your sample data reflects a significant difference from a known population mean.
Syntax
Z.TEST(data, x, [sigma])
- data: The range or array of sample data.
- x: The hypothesized population mean you want to test against.
- sigma: (Optional) The population standard deviation. If not provided, it will be calculated from the sample data.
Example #1
Z.TEST(A1:A10, 5)
This function checks the P-value for a Z-test where the sample data is in cells A1 to A10 and the population mean is hypothesized to be 5. The result will show how likely the sample mean is under this assumption, for instance, a result of 0.03 indicates a 3% probability.
Example #2
Z.TEST(B1:B20, 10, 2)
In this case, the function evaluates the P-value using data from cells B1 to B20, with an assumed population mean of 10 and a known standard deviation of 2. A possible output could be 0.15, meaning there is a 15% chance of observing such a sample mean if the population mean is indeed 10.
Example #3
Z.TEST(C1:C30, 7)
Here, the function is applied to the range C1 to C30, assessing the likelihood of the sample data producing a mean different from the hypothesized value of 7. A result like 0.01 suggests a 1% chance under the null hypothesis, indicating statistical significance.
Error handling
- N/A: Indicates that the function cannot compute the Z-test, typically due to insufficient data.
- VALUE!: This error occurs when the input data is non-numeric or cannot be interpreted as a number.
- REF!: A reference error, which happens when the specified data range does not exist or contains errors.