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

st: RE: nonlinear LS and robust


From   "Chavis, Larry Wilson" <[email protected]>
To   <[email protected]>
Subject   st: RE: nonlinear LS and robust
Date   Mon, 17 May 2004 18:14:00 -0700

Thanks for the help, Kit.  That did the trick.

Regards,
Larry

-----Original Message-----
From: [email protected]
[mailto:[email protected]]On Behalf Of Kit Baum
Sent: Monday, May 17, 2004 1:50 PM
To: [email protected]
Subject: st: nonlinear LS and robust


Larry Chavis couldn't get _robust to work after nl. The trick is 
'leave':

webuse klein,clear
nl log4 consump totinc, leave
tempvar e
mat b = e(b)
mat D= e(V)
predict double `e' if e(sample),r
_robust `e' if e(sample), v(D)
ereturn post b D, depn(`e(depvar)')
ereturn display

without the 'leave' option, _robust can't find the "variable" named b0.

Kit

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

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