[R] "sum" bug?

About this list Date view Thread view Subject view Author view Attachment view

From: Kenneth Cabrera (krcabrer@epm.net.co)
Date: Fri 22 Mar 2002 - 15:19:08 EST


Message-id: <3C9AB0BC.3040609@epm.net.co>

Dear R users and developers:

I got this message when I try to make the summary of a numeric variable,

> summary(Dep)
  
  Min. 1st Qu. Median Mean 3rd Qu. Max.
0.000e+00 1.192e+07 2.739e+07 6.538e+07 1.858e+09
Warning message:
Integer overflow in sum(.); use sum(as.numeric(.))

and it fails to make the sum (for calculate the mean), but I don't
understand the "Integer overflow"

If I type the following command,

> summary(as.numeric(Dep))
     Min. 1st Qu. Median Mean 3rd Qu. Max.
0.000e+00 1.192e+07 2.739e+07 5.306e+07 6.538e+07 1.858e+09

 it works fine.... but I still don't undertand way it doesn't work without
the "as.numeric" coerce, when other functions like "sd()" worked fine.

Thank you very much for your advice

Kenneth Cabrera

P.S.: The length of Dep is 5297
And I am working on W2K in R1.4.1. version.


About this list Date view Thread view Subject view Author view Attachment view

This archive was generated by hypermail 2.1.3 : Wed 16 Oct 2002 - 11:57:08 EST