[Rd] fivenum accuracy (PR#13164)

From: <dleong_at_analogic.com>
Date: Tue, 14 Oct 2008 23:30:09 +0200 (CEST)


Full_Name: David Leong
Version: 2.7.2
OS: Windows XP
Submission from: (NULL) (12.187.86.2)

It appears for the fivenum function, there is a strait average between two ranked samples. This should be a linear interpolation between ranks. For the following data set

#data
CaCO3<-c(130.8,129.9,131.5,131.2,129.5,132.7,131.5,127.8,133.7,132.2,134.8,131.7,133.9,129.8,131.4,128.8,132.7,132.8,131.4,131.3)

fivenum reports 127.80 130.35 131.45 132.70 134.80

130.35 should be 130.125. The other are correct.

For the 20 points, the rank is (20+1)/4=5.25 so the weighting factor is 0.25 not 0.5.



R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Wed 15 Oct 2008 - 09:46:16 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 15 Oct 2008 - 12:30:21 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-devel. Please read the posting guide before posting to the list.

list of date sections of archive