Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: help on user input in ado file


From   "Robert Zimmerman" <[email protected]>
To   <[email protected]>
Subject   st: help on user input in ado file
Date   Thu, 28 Jun 2007 23:07:38 +0200

Dear Statalist,

I am trying to write an ado file to automate a series of commands, but I am
completely new to Stata programming so all I get is error messages. Hope you
can help.

Here is my routine:

local y="y"
local xlist="x1 x2"
reg `y' `xlist'
predict res, r
reg res l.res `xlist'
est table, keep(l.res) p
drop res

I would like to be able to have y, x1 , x2 etc. as user input, so that
myprog.ado would work with:  myprog y x1 x2

Any suggestions?

Thanks in advance,
Robert Zimmerman

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