Statalist The Stata Listserver


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

st: re: estout and test statistics


From   Kit Baum <[email protected]>
To   [email protected]
Subject   st: re: estout and test statistics
Date   Thu, 4 Jan 2007 09:27:13 -0500

Guido asked

My question concnern the inclusion of test statistics in table output
produced by "estout". For instance, is there any way to make estout
display a heteroskedasticity test computed by "estat hettest" following a
conventional linear regression?? I could not figure out any way to
accomplish this via "estadd" etc.

This will do it, using the very latest version of estout (just posted to SSC):

sysuse auto,replace
reg price mpg weight
est store one
estat hettest
local hettest `r(chi2)'
local hetprob `r(p)'
estadd scalar hettest = `hettest'
estadd scalar hetp = `hetprob'
est table, stats(hettest hetp)
estout one,stats(hettest hetp)

You could include any other scalars (e.g. test values from other tests) just by using estadd to put them in e(); either -estimates table- or -estout- will then be able to pick them up. The format suboption could be used in estout to make them prettier.

Kit Baum, Boston College Economics
http://ideas.repec.org/e/pba1.html
An Introduction to Modern Econometrics Using Stata:
http://www.stata-press.com/books/imeus.html


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