Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: change in indexing for stata10


From   "Nick Cox" <[email protected]>
To   <[email protected]>
Subject   st: RE: change in indexing for stata10
Date   Thu, 15 Nov 2007 19:26:37 -0000

There was no change in indexing in 10. 
Caleb might try -do- rather than -run-.  

Nick
[email protected] 

Caleb Southworth

Was there a change in indexing between Stata 9 & 10?

In Stata 9, this generates a list of ids:

forval i = 1/65 {
 	di id[`i']
}

In Stata 10, the same loop on the same data generates no output.

. set trace on

. run "C:\DOCUME~1\cjs\LOCALS~1\Temp\STD05000000.tmp"
- forval i = 1/65 {
- di id[`i']
= di id[1]
- }
- di id[`i']
= di id[2]
- }
- di id[`i']
= di id[3]
- }
[snip]

But

. di id[1]
7

Let me know where I've gone wrong.

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   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