[Rd] stats::line() does not produce correct Tukey line when n mod 6 is 2 or 3

Serguei Sokol sokol at insa-toulouse.fr
Tue May 30 16:01:17 CEST 2017


Le 30/05/2017 à 09:33, Martin Maechler a écrit :
...
> However, even after the patch,
> The example from the SO post differs from the result of Richie
> Cotton's function...
The explanation is quite simple. In SO function, the first 1/3 quantile
of used example counts 6 points (of 19 in total), while line()'s
definition of quantile leads to 8 points. The same numbers
(6 and 8) are on the other end of sample. In x sample, there are
few repeated values, this is certainly be the reason of different quantiles..

I am not sure that one quantile definition is better or more correct
than the other. So I would leave line()'s definition as is.

Best,
Sergueï.



More information about the R-devel mailing list