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: foreach command


From   megan rossi <[email protected]>
To   <[email protected]>
Subject   st: RE: foreach command
Date   Thu, 13 Dec 2012 10:26:53 +1000

Hi all,
I am trying to use the loop function on a set of pre -existing variables 
variable 1) total_IS_0
variable 2) free_IS_0 
Variable 3) total_PCS_0 
Variable 4) free_PCS_0 
My syntax is....
foreach 'var' of varlist total_IS_0 free_IS_0 total_PCS_0 free_PCS_0 {
summarize 'var'
}
I have stat 12 and it is coming up with r 198 invalid name... I am not sure what is wrong with my syntax? Also is there a way to incorporate this loop function with the drop down selections option or is it only avaliable with manual entry?
Cheers,

PhD Candidate School of Medicine, University of Queensland
Accredited Practicing Dietitian
Princess Alexandra Hospital Nutrition & Dietetic Department
m: 0402 931 441 | e: [email protected]
"Let food be thy medicine and medicine be thy food." — Hippocrates (ca. 460 – 377 BC)
********************************************************************************
This email, including any attachments sent with it, is confidential and for the sole use of the intended recipient(s). This confidentiality is not waived or lost, if you receive it and you are not the intended recipient(s), or if it is transmitted/received in error.
Any unauthorised use, alteration, disclosure, distribution or review of this email is strictly prohibited. The information contained in this email, including any attachment sent with it, may be subject to a statutory duty of confidentiality if it relates to health service matters.
**********************************************************************************
----------------------------------------
> Date: Wed, 12 Dec 2012 18:25:34 -0500
> Subject: Re: st: fixed effects quantile regression
> From: [email protected]
> To: [email protected]
>
> On Wed, Dec 12, 2012 at 2:49 PM, Austin Nichols <[email protected]> wrote:
> > JVerkuilen (Gmail) <[email protected]>:
> > -suest- does not work with -qreg-.
>
> :(
>
>
>
> > Lisa Marie Yarnell <[email protected]>:
> > On -qreg- with FE, there are many different forms, all interpreted differently.
> > See e.g.
> > http://www.rand.org/content/dam/rand/pubs/working_papers/2012/RAND_WR710-2.pdf
> > for a good review of how people have tackled it.
>
> That's a nice reference, thanks.
>
> Jay
> *
> * For searches and help try:
> * http://www.stata.com/help.cgi?search
> * http://www.stata.com/support/faqs/resources/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/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index