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 at the end of May, and its replacement, statalist.org is already up and running.


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

st: command's options as macro


From   tashi lama <ltashi32@hotmail.com>
To   <statalist@hsphsun2.harvard.edu>
Subject   st: command's options as macro
Date   Thu, 26 Jul 2012 18:58:20 +0000

Hello all, 
       Could someone attempt to explain this to me? I just can't get over this hump. 

local m1= title[1]
local note1 "note" "(" `"" 1  `m1'" "' ")" 
local note2   1 `m1' 
di "`note1'"
note(" 1  2011" )

di "`note2'"
1 2011

tsline hits, "`note1'"
invalid syntax although if you write it out, it would be  tsline hits, note("1 2011") which looks fine 
tsline hits, note("`note2'") stata is happy 

Thanx.. 		 	   		  
*
*   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