You too have fallen victim to floating point error (see FAQ 7.31).
> (100*.58) == 58 [1] FALSE > (100*.58) < 58 [1] TRUE On Fri, Jul 9, 2010 at 9:46 AM, Trafim Vanishek <rdapam...@gmail.com> wrote: > Dear all, > > might seem and easy question but I cannot figure it out. > > floor(100*(.58)) > [1] 57 > > where is the trick here? And how can I end up with the right answer? > > Thanks a lot everybody for your help. > Trafim > -- Sarah Goslee http://www.functionaldiversity.org ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.