Message-ID: <1351529787791-4647774.post@n4.nabble.com>
Date: 2012-10-29T16:56:27Z
From: fxen3k
Subject: Hausman test in R
In-Reply-To: <CACk-te0RQgCcTQnWe5RXXNAHsvadP0Loi2ejG=R_3bcLvNZHrQ@mail.gmail.com>
Given my "acknowledged statistical ignorance", I tried to find a *solution
*in this forum...
And this is not primarily a statistical issue, it is an issue about the
Hausman test in the R environment.
I cannot imagine, no one in this forum has ever done a Hausman test on OLS
regressions.
I read in the systemfit package and found only this example referring to
2SLS and 3SLS regressions:
data( "Kmenta" )
eqDemand <- consump ~ price + income
eqSupply <- consump ~ price + farmPrice + trend
inst <- ~ income + farmPrice + trend
system <- list( demand = eqDemand, supply = eqSupply )
## perform the estimations
fit2sls <- systemfit( system, "2SLS", inst = inst, data = Kmenta )
fit3sls <- systemfit( system, "3SLS", inst = inst, data = Kmenta )
## perform the Hausman test
h <- hausman.systemfit( fit2sls, fit3sls )
print( h )
--
View this message in context: http://r.789695.n4.nabble.com/Hausman-test-in-R-tp4647716p4647774.html
Sent from the R help mailing list archive at Nabble.com.