Hoerl_Kernard ridge regression method
[rridge]=ridge1(y,x,theta)
* y = a (n x 1) vector
* x = a (n x k) vector
* theta = a scalar, theta's value
* 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('theta') = the scale factor theta
- 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
load(GROCERDIR+'data\bdhenderic.dat') [y,namey,x]=explouniv('delts(lm1-lp)',['delts(lp)','delts(lagts(1,lm1-lp-ly))','rnet','lagts(1,lm1-lp-ly)','cte'],['1964q3';'1989q2']); // perform the ridge regression on the corresponding variables with theta=0.001 result=ridge1(y,x,0.001) // display the estimated coefficients: result('beta') | ![]() | ![]() |