Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: forvalues i = 0(.05).15


From   David Airey <[email protected]>
To   Statalist <[email protected]>
Subject   st: forvalues i = 0(.05).15
Date   Mon, 9 Nov 2009 08:50:52 -0600

.

The fact that forvalues

forvalues i = (0)(.05).15 {
display `i'
}

gives


. forvalues i = 0(.05).15 {
  2. display `i'
  3. }
0
.05
.1

is related to accuracy of a macro or float right (.15 is missing)?

I could alternatively type:

forvalues i = 0(5)15 {
display `i'/10
}

or

forvalues i = 0(.05).16 {
display `i'
}


*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index