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

st: results of -testparm- in table by estimate


From   "E. Michael Foster (UNC_SPH)" <[email protected]>
To   [email protected]
Subject   st: results of -testparm- in table by estimate
Date   Thu, 25 Aug 2005 11:08:25 -0400

Hi,

I want to feed the results of -testparm- to -est-, but -testparm-
outputs r-class not e-class (and my understanding is that -est- can
include e() scalars)

so, I tried to trick the program (famous last words)

program define check , eclass
 	testparm x*			// the regressors in question start with x
 	ereturn scalar myp=r(p)	// an -ereturn list- shows this worked
 	end

      reg y x*  w1 w2 // and so on
      est store regr1
      est for regr1 : check

       est table regr1 , stats(N myp)

No sign of myp in the table!  just a blank row, appropriately labelled.

Where am I screwing up?

professor of maternal and child health
university of north carolina

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