Learn R Programming

systemfit (version 0.7-1)

hausman.systemfit: Hausman's Test

Description

hausman returns the Hausman's statistic for specification. $$q'(V_1 - V_0)q$$ where $V_1$ and $V_0$ are the covb values from a twostage or threestage object and q is the difference in the b vectors from the twostage or threestage objects.

Usage

hausman.systemfit( li.results, fi.results )

Arguments

li.results
the limited information results object (twostage)
fi.results
the full information results object (threestage)

Value

  • hausman.systemfit returns the value of the test statistic.

References

Greene, W. H. (1993) Econometric Analysis, Second Edition, Macmillan. Hausman, J. A. (1978) Specification Tests in Econometrics. Economtrica. 46:1251-1271. Kmenta, J. (1997) Elements of Econometrics, Second Edition, University of Michigan Publishing

See Also

systemfit

Examples

Run this code
library( systemfit )

data( kmenta )
attach( kmenta )
demand <- q ~ p + d
supply <- q ~ p + f + a
inst <- ~ d + f + a
labels <- list( "demand", "supply" )
system <- list( demand, supply )

## perform the estimation and report the results for the whoel system
fit2sls <- systemfit( "2SLS", system, labels, inst)
fit3sls <- systemfit( "3SLS", system, labels, inst)

## perform the hausman test on the first equation
h <- hausman.systemfit( fit2sls, fit3sls )
pval <- pchisq( h, dim( fit3sls$bcov )[1] )

print( h )
print( pval )

Run the code above in your browser using DataLab