Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: automatically added decimals in Stata
From
"Ruizendaal, Esmee" <[email protected]>
To
"[email protected]" <[email protected]>
Subject
st: automatically added decimals in Stata
Date
Tue, 18 Mar 2014 14:15:26 +0000
Dear statalist,
I noticed a weird thing in my stata data file. When viewing my data I see for example the value 186.6, which is the correct value. However when I select the cell, it shows that the real value is 186.60001 and this is happening quite randomly in many cells, value 6.2 is made into 6.1999998, while value 14.5 remains just 14.5.
These examples are all from the same column, but it is also happening in other columns. Even if I re-enter my data it changes to these weird numbers with many decimals again (adding or subtracting .00001). I have tried to play a bit with the variable type and format (type is currently float and format %9.0g), but that does not help (or I am left with no decimals at all).
Does anyone know why this is happening and how I can solve it? Thanks for your time!
Kind regards,
Esmée
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/