[R] Difference

Uwe Ligges ligges at statistik.uni-dortmund.de
Tue Apr 19 10:31:16 CEST 2005


Ralf Strobl wrote:

> Dear List,
> can anyone explain me this result (Windows XP, R 2.0.1):
> 
>  > (0.2-0.1)==0.1
> [1] TRUE
>  > (0.3-0.2)==0.1
> [1] FALSE


Welcome to the world of numerics on digital computers!

   all.equal(0.3 - 0.2, 0.1)


Uwe Ligges


> Regards,
> Ralf Strobl
> 
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! 
> http://www.R-project.org/posting-guide.html




More information about the R-help mailing list