[R] Integer precision etc.

Simon Fear Simon.Fear at synequanon.com
Wed Aug 13 16:01:35 CEST 2003

1e100 is just one example of much bigger number that is exactly
(in floating point). But of course
> 1e100+1 - 1e100
[1] 0

You mean the biggest number such that adding one changes the result?

I should be extremely careful with

> print( 9007199254740994, digits=20)
[1] 9007199254740994
> print( 9007199254740994-1, digits=20)
[1] 9007199254740992

Here subtracting one makes a difference of two ... but the numbers look

Simon Fear
Senior Statistician
Syne qua non Ltd
Tel: +44 (0) 1379 644449
Fax: +44 (0) 1379 644445
email: Simon.Fear at synequanon.com
web: http://www.synequanon.com
Number of attachments included with this message: 0
This message (and any associated files) is confidential and\...{{dropped}}

More information about the R-help mailing list