Re: [R] Bug? in summary( ) function base package

From: Mike Prager <mike.prager_at_noaa.gov>
Date: Wed, 30 Apr 2008 16:33:31 -0400

"Richard Saba" <sabaric_at_auburn.edu> wrote:

> There seems to be an error in the summary() function when applied to "ts"
> class objects. The results of a call to summary( ), on the R "ts" data set
> USAccDeaths , reports the wrong value for Max. The value reported by the
> summary function is 11320. The max( ) function returns the correct value
> 11317, the July 1993 value. Coercing the data to a data.frame and calling
> summary returns the correct max value. A search of R -help found a post in
> 2007 that mentioned a problem but attributed it to rounding errors. But this
> is too large a difference to account for a simple rounding error.
>
> Has anyone else encountered the problem? Is there a workaround?

A documented feature of summary() is that it rounds values. In doing so, it may print meaningless digits and thus give the appearance of more precision than is really represented.

-- 
Mike Prager, NOAA, Beaufort, NC
* Opinions expressed are personal and not represented otherwise.
* Any use of tradenames does not constitute a NOAA endorsement.

______________________________________________
R-help_at_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.
Received on Wed 30 Apr 2008 - 21:13:02 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 30 Apr 2008 - 21:30:42 GMT.

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

list of date sections of archive