Just to put this topic to rest: The hinges match quantile(x, probs = c(1,3)/4, type = 2) except when n = 3 mod 4.
I no longer have Tukey's EDA book, but I think that his idea was that hinges (aka quartiles) were defined as medians of the lower/upper halves of the (sorted, of course) data, where a 'half' would include the median for odd sample sizes. And that's how they are calculated in fivenum(). Thus hinges are a 10th definition of quartiles, but they don't lend themselves to generalization to arbitrary quantiles other than, say, octiles or other (1/2^k)-iles. -Peter On 2010-05-13 11:47, David Winsemius wrote:
I agree. I was convinced by Ehlers' example that type =2 was a better match to fivenum's result
-- Peter Ehlers University of Calgary ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.