Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Re: How to speed up loop


From   Friedrich Huebler <[email protected]>
To   [email protected]
Subject   st: Re: How to speed up loop
Date   Wed, 15 Sep 2004 10:20:02 -0700 (PDT)

Many thanks to all who responded and especially to Nick, who had the
fastest solution. As an example, with one of my datasets the loop
takes 30.1 seconds to create mage. The command suggested by Nick
takes 0.08 seconds.

Friedrich

--- Nick Cox <[email protected]> wrote:
> Looks like 
> 
> by hhid : gen mage = age[mlineno] 
> 
> to me. No loops, no -merge-.
> 
> Nick 
> [email protected] 



		
__________________________________
Do you Yahoo!?
Yahoo! Mail Address AutoComplete - You start. We finish.
http://promotions.yahoo.com/new_mail 
*
*   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/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index