Skip to content

<= returns wrong result? Why

5 messages · Trafim Vanishek, Liviu Andronic, Peter Ehlers +2 more

#
On 1/13/10, Trafim Vanishek <rdapamoga at gmail.com> wrote:
I would suspect that, if you're looking at all the digits, the two are
not exactly the same. I would try
round(Rk[47], 10) <= round(RB[21], 10)

Liviu
#
Trafim Vanishek wrote:
What makes you think that Rk[47] and RB[21] are equal? You're only
showing 9-decimal print versions.

  -Peter Ehlers

  
    
#
Hi Trafim,

take a look at FAQ 7.31.

HTH
Stephan


Trafim Vanishek schrieb:
#
Yupp, FAQ 7.31 is definitely your friend here.

You might also want to take a look at these two very recent threads on 
this help list:

"Strange behaviour of as.integer()"
http://tolstoy.newcastle.edu.au/R/e9/help/10/01/index.html#547

"Newbie question on precision"
http://tolstoy.newcastle.edu.au/R/e9/help/10/01/index.html#718

Best,
Magnus
On 1/13/2010 3:25 AM, Stephan Kolassa wrote: