Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, statalist.org is already up and running.


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

st: ocal macros & do file


From   Anjanette Chan Tack <amc75@uchicago.edu>
To   statalist@hsphsun2.harvard.edu
Subject   st: ocal macros & do file
Date   Tue, 26 Apr 2011 15:33:39 -0500 (CDT)

I made a local macro in stata called `access', then a made a do file with a host of commands that use `access'. When I run the do file, it executes some commands without a problem, but it fails to execute others.

To test the whether the commands that fail are typed properly in the do file, I copy-and-pasted them into the stata command window. When I press enter, the commands work perfectly. Have any of you come across something like this?

I can't figure out what the problem is. Obviously, I want to be able to run the do-files and not have to enter these commands on at a time. Additional info: I am using stata 9. Also, all the commands that work are of the form:

tab x, summ(`access')

Whereas the ones that fail are all of the form:

tab x y, summ(`access') means

One would think such commands too simple to cause confusion, but there it is. Thanks a lot in advance for your help!

Anjie. 
-------------------------------
Anjanette M. Chan Tack
PhD student 
University of Chicago Department of Sociology
*
*   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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index