[R] max & summary contradict each other

Duncan Murdoch murdoch.duncan at gmail.com
Fri Sep 28 18:22:10 CEST 2012


On 28/09/2012 12:14 PM, Sam Steingold wrote:
> why does summary report max 27600 and not 27603?
>
> > x <- c(27603, 1)
> > max(x)
> [1] 27603
> > summary(x)
>     Min. 1st Qu.  Median    Mean 3rd Qu.    Max.
>        1    6902   13800   13800   20700   27600
>

Because you asked for 3 digit accuracy.  See ?summary.

Duncan Murdoch




More information about the R-help mailing list