Bookmark and Share

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]

re: RE: st: For each loop


From   Christopher Baum <[email protected]>
To   "[email protected]" <[email protected]>
Subject   re: RE: st: For each loop
Date   Sun, 30 Oct 2011 10:30:05 -0400

<>
thanks for your help. 
sum tobin_q_* works. 
However, I also tried
forvalues i=2000/2010 {sum tobin_q_'i'}
and it gave the same error message. Do you know why it might happen ?

Because you didn't heed my prior message. 

Furthermore it looks like you are using ' on the LHS of the macro rather than `. Read my recent posting "Code from Stata Journal" about the difference.

Kit


Kit Baum   |   Boston College Economics & DIW Berlin   |   http://ideas.repec.org/e/pba1.html
                             An Introduction to Stata Programming  |   http://www.stata-press.com/books/isp.html
  An Introduction to Modern Econometrics Using Stata  |   http://www.stata-press.com/books/imeus.html


*
*   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–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index