<< qreg1 Single equation regressions robust >>

Grocer >> Single equation regressions > ridge

ridge

ridge regression

CALLING SEQUENCE

[rridge]=ridge(namey, arg1,...,argn)

PARAMETERS

Input

* grocer_namey = a time series, a real (nx1) vector or a string equal to the name of a time series or a (nx1) real vector between quotes; all values should be 0 or 1.

* argi = an argument which can be:

* argi = arguments which can be:

  - a time series

  - a real (nx1) vector

  - a real (nxk) matrix

  - a string equal to the name of a time series or a (nxk) real vector or matrix between quotes

  - a list of such elemnts

  - the string 'noprint' if the user doesn't want to display the results of the regression

  - the string 'theta=xx' if the user wants to enter theta's value (default is the one recommended by Hoerl and Kennard)

 

Output

* rridge = a tlist with

  - rridge('meth') = 'ridge'

  - rridge('y') = y data vector

  - rridge('x') = x data matrix

  - rridge('nobs') = nobs

  - rridge('nvar') = nvars

  - rridge('beta') = bhat

  - rridge('yhat') = yhat

  - rridge('resid') = residuals

  - rridge('vcovar') = estimated variance-covariance matrix of beta

  - rridge('sige') = estimated variance of the residuals

  - rridge('sige') = estimated variance of the residuals

  - rridge('ser') = standard error of the regression

  - rridge('tstat') = t-stats

  - rridge('pvalue') = pvalue of the betas

  - rridge('dw') = Durbin-Watson Statistic

  - rridge('prescte') = boolean indicating the presence or absence of a constant in the regression

  - rridge('rsqr') = rsquared

  - rridge('rbar') = rbar-squared

  - rridge('f') = F-stat for the nullity of coefficients other than the constant

  - rridge('pvaluef') = its significance level

  - rridge('prescte') = boolean indicating the presence or absence of a time series in the regression

  - rridge('namey') = name of the y variable

  - rridge('namex') = name of the x variables

  - rridge('bounds') = if there is a timeseries in the regression, the bounds of the regression

  - rridge('theta') = the scale factor theta

DESCRIPTION

Computes Hoerl-Kennard Ridge Regression, using either the theta value entered by the user or the default one recommended by Hoerl and Kennard. Endogenous variable must be given first, as a vector, a ts, between quotes (if the user wants to keep the name of the variable in the tlist result and for the printings) or not. Exogenous variables are given after, in one of the formats authorized for the endogenous one, or in matrix format. The program displays on screen various results (coefficients, tstat, R², Durbin and Watson, first order autocorrelation of residuals,...) except if the user has entered the argument 'noprint' anywhere after the first argument.

EXAMPLE

load('grocer/bdexamples/bdhenderic.dat') ; bounds('1964q3','1989q2') ;
r= ridge('del(lm1-lp)','del(lp)','del(lagts(1,lm1-lp-ly))','rnet','lagts(1,lm1-lp-ly)','cte')
r = ridge('del(lm1-lp)','del(lp)','del(lagts(1,lm1-lp-ly))','rnet','lagts(1,lm1-lp-ly)','cte', 'theta=0.001')
// These examples shows the results of a ridge regression on Hendry and Ericsson's preferred regression,
// using for theta the default parameter in example 1 and 0.001 in example 2.

AUTHOR

Eric Dubois 2002

Report an issue
<< qreg1 Single equation regressions robust >>