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]

st: RE: Declaring several local variables at once


From   "Martin Weiss" <[email protected]>
To   <[email protected]>
Subject   st: RE: Declaring several local variables at once
Date   Thu, 5 Aug 2010 20:02:16 +0200

<>

-local-s tend to vanish once the -program- stops anyway, but you can of
course -macro drop _all- should you so wish...

Stata thinks your -local- "a" contains the string "b c=0", btw:

***
loc a b c=0
di "`a'"
***


HTH
Martin


-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Dani Tilley
Sent: Donnerstag, 5. August 2010 19:59
To: stata
Subject: st: Declaring several local variables at once

Hi,

I was wondering how you can declare more than one local var in one line.

I tried -loc a b c=0- and it returned no error. But -di `a'- returned
r(111). 
Also, is there a way to `drop' the locals after your program ends?

Thanks in advance.

DF Tilley



      

*
*   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/

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