[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
Re: st: RE: inner loop
defining the IDs the nested for runs fine now.
The replace command picks one var out of a bunch of vars. I just dropped
the ifs for simplicity.
James Jetton schrieb:
> Hans J. Baumgartner
> > is it possible to run an inner loop using the for command?
> > I think it is
> > not possible but could someone point me to a command that allows for
> > such an inner loop?
> > What I would like to do is basically the following:
> > for any a b c: for num 1984/2000: replace z=YX
> Nested for loops often fail if the ids are not explicitly specified.
> For example
> for any a b c: for num 1984/2000:
> will fail but
> for X in any a b c: for Y in num 1984/2000:
> will work.
> This appears to be a bug in the for ado. Been bitten by this
> hemipteran more than once.
> Although I'm not sure what you are trying to do with "replace z=YX".
> James Jetton
> * For searches and help try:
> * http://www.stata.com/support/faqs/res/findit.html
> * http://www.stata.com/support/statalist/faq
> * http://www.ats.ucla.edu/stat/stata/
Hans J. Baumgartner
Deutsches Institut für Wirtschaftsforschung (DIW Berlin)
German Institute for Economic Research
Abt. Staat / Dept. Public Sector
Königin-Luise-Str. 5; 14195 Berlin (Dahlem)
Tel.: 030/89789-307; Fax.: 030/89789-114
* For searches and help try: