[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: re: question about "testparm"

From   Kit Baum <>
Subject   st: re: question about "testparm"
Date   Sun, 1 Feb 2009 14:05:36 -0500

Martin said, quoting another respondent:

"Then, you would need to run your -testparm- 3 separate times: one for
Var1/Var2, another for Var1/Var3, and a third for Var2/Var3."

See my code segment in my earlier code:

webuse highschool, clear
svy: regress weight height state county school
test he=sch
test he=state,accum
test scho=state,accum

For one thing this is an obsolete (but acceptable) form of -test-. It can also be written

test (height = school) (height = state) (school = state)

but this misses the point, made in my earlier posting, that there are NOT 3 tests to be performed, but two. Thus the parsimonious form of this joint test is merely

test height = state = school

which properly shows that there are two constraints to be applied to the parameter vector. I teach students that the number of constraints in a test is the number of equals signs you must write down to specify it properly. In this case the latter form shows 2, which is right, rather than 3.

I deplore the use of abbreviated variable names in posted examples. IMHO -set varabbrev on- is a terrible idea (whether or not it is the official default*), and examples should run with it off.


* As for software developers' omniscience in the definition of default settings, remember that Windows developers argued for some time that leaving a crucial security setting OFF by default was better for their users because they wouldn't have to figure out how to change it.

Kit Baum, Boston College Economics and DIW Berlin
An Introduction to Modern Econometrics Using Stata:

*   For searches and help try:

© Copyright 1996–2021 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index