Grocer Function
NAME
bpagan - Breusch and Pagan heteroskedasticity test
CALLING SEQUENCE
[resulbp]=bpagan(resulols,arg1,...,argn)
PARAMETERS
Input
-
resulols = results tlist from a first stage estimation
-
argi = arguments of the second stage regression, which can be:
- a time series
- a real (nxp) vector
- a string equal to the name of a time series or a (nxp) real vector between quotes
- the string 'noprint' if the user doesn't want to print the results of the regression
Output
-
resulbp = a results tlist with:
- resulbp('meth') = 'bpagan'
- resulbp('resul1st') = results tlist of the first stage regression
- resulbp('u2') = sum of square residuals from the first stage regression
- resulbp('namex2') = names of the exogenous variables in the second stage regression
- resulbp('x2') = vector of the exogenous variables in the second stage regression
- resulbp('f') = Breush-Pagan LM-statistic (Fisher form)
- resulbp('p') = p-value of the test
- resulbp('dfnum') = degrees of freedom of the numerator
- resulbp('dfden') = degrees of freedom of the denominator
- resulbp('f_pvalue) = p-value of the test
DESCRIPTION
Computes Breusch and Pagan heteroskedasticity test with the exogenous second stage variables provided by the user (see Breusch, T.S. and A.R. Pagan (1979): "A simple test for heteroscedasticity and random coefficient variation", Econometrica 47, 1287-1294). Results are stored in a tlist and displayed on screen.
EXAMPLE
bpagan(rols,'del(lp)','del(lagts(1,lm1-lp-ly))','rnet','lagts(1,lm1-lp-ly)','cte','(del(lp))^2', '(del(lagts(1,lm1-lp-ly)))^2','(rnet)^2','(lagts(1,lm1-lp-ly))^2')
This example is taken from bpagan_d. The first stage result comes from the estimation of Hendry and Ericsson equation # 6. The second stage exogenous variables are the squares of all exogenous variables of the first stage regression.
AUTHOR
Eric Dubois 2002