Hello, On Tue, Oct 09, 2018 at 01:14:54PM -0400, Ryan Derickson wrote: > Apologies if this is a simple misunderstanding.
See for example: https://cran.r-project.org/doc/FAQ/R-FAQ.html#Why-doesn_0027t-R-think-these-numbers-are-equal_003f > round((.575*100),0) gives 57 > round(57.5,0) gives 58 > > Why? Not R related at all. $ python Python 2.7.13 (default, Sep 26 2018, 18:42:22) [GCC 6.3.0 20170516] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> round((.575*100),0) 57.0 >>> round(57.5,0) 58.0 Same "issue". :) You'll need to dig into how numbers are floating numbers are represented in a finite set. Cheers, -- BenoƮt Vaillant
signature.asc
Description: PGP signature
______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see 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.