GNOME Bugzilla – Bug 614746
ZTEST documentation is wrong
Last modified: 2010-04-05 18:48:32 UTC
Hello: I have detected two problems in Gnumeric 1.9.13. FIRST: the chi-square distribution has two tails and both are important. But you provide the user with upper tail values only. Lower tail values are lacking and they cannot be calculated by the user. The same happens with the F distribution. SECOND: In the description of the ZTEST you say: ZTEST: p-value of a 2-tailed z-test for a population mean. This description is wrong. The correct description must be: ZTEST: p-value of an upper-tailed z-test for a population mean. You can get convinced of this is you run a ZTEST with the following data: Row data: -1, 0, 1. Expected mean=0. Population standard deviation = 1. Because the sample mean and the expected mean coincide and are zero, a 2-tailed z-test must evaluate to 1. But Gnumeric evaluates it to 0.5 meaning that the ZTEST is just with one tail. To conclude that your ZTEST works with the upper tail, run the same experiment but with an expected mean of -1. In that case, the p-value must be positive for the upper trial, such as it happens. José Rodríguez
Both tails of the chi square distribution can easily be calculated with 1-CHIDIST (...) or R.PCHISQ.
I thought we had fixed the ztest doc already, but apparently not.
This problem has been fixed in the development version. The fix will be available in the next major software release. Thank you for your bug report.