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

st: Is Stata smart enough to avoid unnecessary repetition?


From   Richard Williams <[email protected]>
To   [email protected]
Subject   st: Is Stata smart enough to avoid unnecessary repetition?
Date   Sat, 13 Dec 2003 19:29:49 -0500

Is Stata smart enough to know when it already has the necessary information calculated for an estimation command? For example, if I do

regress y x1 x2 x3
regress y x1 x2 x3

will stata redo the regression or will it know that it has already done it and just replay the results? Or, less obviously, if you do something like

regress y x1 x2 x3
pcorr y x1 x2 x3

the -pcorr- command will quietly regress y x1 x2 x3. Will Stata do that regression anew or does it know it doesn't need to bother?

If Stata is smart enough to avoid repetition, will it also be smart enough to know that it must start from scratch if the data have been edited or changed?

Put another way, does it make any difference whether I just replay results (e.g. type -regress- with no arguments) as opposed to repeating the original complete command?

I've been using Stata with small data sets and it seems extremely fast. But, I may start using it with some enormous data sets, and I'm also starting to write some ado files, and I'm wondering whether I have to worry about how efficient my commands are or if Stata will choose the optimal strategy.



-------------------------------------------
Richard Williams, Associate Professor
OFFICE: (574)631-6668, (574)631-6463
FAX: (574)288-4373
HOME: (574)289-5227
EMAIL: [email protected]
WWW (personal): http://www.nd.edu/~rwilliam
WWW (department): http://www.nd.edu/~soc

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