JRosten@lehman.com
2004-Sep-07 11:24 UTC
[Rd] FW: Problems with floor, round functions (PR#7215)
Please disregard the previous bug report. It appears that the session I was running had become corrupted and a new one is not reproducing the errors described. thanks> -----Original Message----- > From: Rosten, Jeremy > Sent: Tuesday, September 07, 2004 9:44 AM > To: 'R-bugs@R-project.org' > Subject: Problems with floor, round functions > > Hi > > I am currently using version 1.6.2 ( I am in the process of getting 1.9.1 > installed) and perhaps this is an old problem that has been resolved. > > Anyway hat I am seeing is the following: > > > floor(4.99) > [1] 4 > > 0.01*floor(4.99) > [1] 0.03 > > And : > 0.01*(floor(4.99)+0.00000000001) > [1] 0.04 > > Even when I do: > > as.numeric(as.character(floor(4.99)))+0.1 > > I get: > > [1] 4.0 > > This happens with round and ceiling as well . > > Thanks > > Jeremy Rosten > >------------------------------------------------------------------------------ This message is intended only for the personal and confidential use of the designated recipient(s) named above. If you are not the intended recipient of this message you are hereby notified that any review, dissemination, distribution or copying of this message is strictly prohibited. This communication is for information purposes only and should not be regarded as an offer to sell or as a solicitation of an offer to buy any financial product, an official confirmation of any transaction, or as an official statement of Lehman Brothers. Email transmission cannot be guaranteed to be secure or error-free. Therefore, we do not represent that this information is complete or accurate and it should not be relied upon as such. All information is subject to change without notice.