varsel |

Estimation by stepwise least squares.

Syntax

varsel(options) y x1 [x2 x3 ...] @ z1 z2 z3

Specify the dependent variable followed by a list of variables to be included in the regression, but not part of the search routine, followed by an “@” symbol and a list of variables to be part of the search routine. If no included variables are required, simply follow the dependent variable with an “@” symbol and the list of search variables.

Options

method = arg | Stepwise regression method: “stepwise” (default), “uni” (uni-directional), “swap” (swapwise), “comb” (combinatorial), “gets” (auto-search/GETS), “lasso” (Lasso). |

nvars = int | Set the number of search regressors. Required for swapwise and combinatorial methods, optional for uni-directional and stepwise methods. |

w=arg | Weight series or expression. Note: we recommend that, absent a good reason, you employ the default settings Inverse std. dev. weights (“wtype=istdev”) with EViews default scaling (“wscale=eviews”) for backward compatibility with versions prior to EViews 7. |

wtype=arg (default=“istdev”) | Weight specification type: inverse standard deviation (“istdev”), inverse variance (“ivar”), standard deviation (“stdev”), variance (“var”). |

wscale=arg | Weight scaling: EViews default (“eviews”), average (“avg”), none (“none”). The default setting depends upon the weight type: “eviews” if “wtype=istdev”, “avg” for all others. |

coef=arg | Specify the name of the coefficient vector (if specified by list); the default behavior is to use the “C” coefficient vector. |

prompt | Force the dialog to appear from within a program. |

p | Print estimation results. |

Stepwise and uni-directional method options

back | Set stepwise or uni-directional method to run backward. If omitted, the method runs forward. |

tstat | Use t-statistic values as a stopping criterion. (default uses p-values). |

ftol=number (default = 0.5) | Set forward stopping criterion value. |

btol=number (default = 0.5) | Set backward stopping criterion value. |

fmaxstep=int (default = 1000) | Set the maximum number of steps forward. |

bmaxstep=int (default = 1000) | Set the maximum number of steps backward. |

tmaxstep=int (default = 2000) | Set the maximum total number of steps. |

Swapwise method options

minr2 | Use minimum R-squared increments. (Default uses maximum R-squared increments.) |

Combinatorial method options

force | Suppress the warning message issued when a large number of regressions will be performed. |

Auto-search/GETS method options

pval=number (default = 0.05) | Set the terminal condition p-value used to determine the stopping point of each search path |

nolm | Do not perform AR LM diagnostic test. |

arpval=number (default = 0.025) | Set p-value used in AR LM diagnostic test. |

arlags=int (default = 1) | Set number of lags used in AR LM diagnostic test. |

noarch | Do not perform ARCH LM diagnostic test. |

archpval=number (default = 0.025) | Set p-value used in ARCH LM diagnostic test. |

archlags=int (default = 1) | Set number of lags used in ARCH LM diagnostic test. |

nojb | Do not perform Jarque-Bera normality diagnostic test. |

jbpval=number (default = 0.025) | Set p-value used in Jarque-Bera normality diagnostic test. |

nopet | Do not perform Parsimonious Encompassing diagnostic test. |

petpval=number (default = 0.025) | Set p-value used in Parsimonious Encompassing diagnostic test. |

nogum | Do not include the general model as a candidate for model selection. |

noempty | Do not include the empty model as a candidate for model selection. |

ic =arg | Set the information criterion used in model selection: “AIC” (Akaike information criteria, default), “BIC” (Schwarz information criteria), “HQ” (Hannan-Quin criteria). |

blocks=int | Override the EViews’ determination of the number of blocks in which to split the estimation sample. |

Lasso method options

General options

xtrans=arg (default=“none”) | Transformation of the regressor variables: “none” (none), “L1” (L1), “L2” (L2), “stdsmpl” (sample standard deviation), “stdpop” (population standard deviation), “minmax” (min-max). |

lambdaratio=arg (default=0.0001) | Ratio of minimum to maximum lambda for EViews-supplied list. |

nlambdas=arg (default=100) | Number of lambas for EViews-supplied list. |

s | Use the current coefficient values in estimator coefficient vector as starting values (see also
param). |

s=number (default=1) | Specify a number between zero and one to determine starting values as a fraction of OLS values (out of range values are set to “s=1”). |

maxit=integer | Maximum number of iterations. |

conv=scalar | Set convergence criterion. The criterion is based upon the maximum of the percentage changes in the scaled estimates. The criterion will be set to the nearest value between 1e-24 and 0.2. |

showopts / ‑showopts | [Do / do not] display the starting coefficient values and estimation options in the rotation output. |

coef=arg | Specify the name of the coefficient vector (if specified by list); the default behavior is to use the “C” coefficient vector. |

lambda=arg | Value of the penalty parameter. Can be a single number, list of space-delimited numbers, a workfile series object, or left blank for an EViews-supplied list (default). Values must be zero or greater. |

w=arg | Weight series or expression. |

wtype=arg (default=“istdev”) | Weight specification type: inverse standard deviation (“istdev”), inverse variance (“ivar”), standard deviation (“stdev”), variance (“var”). |

wscale=arg | Weight scaling: EViews default (“eviews”), average (“avg”), none (“none”). The default setting depends upon the weight type: “eviews” if “wtype=istdev”, “avg” for all others. |

Cross Validation Options

cvmathod=arg (default=“kfold_cv”) | Cross-validation method: “kfold” (k-fold), “shuffle” (shuffle), “leavepout” (leave p out), “leave1out” (leave one out). |

cvmeasure=arg (default=“mse”) | Error measurement from cross-validation: “mse” (mean-squared error), “mae” (mean absolute error), “r2” (r-squared). |

training=arg (default=0.8) | Proportion of data or number of data points in training set for shuffle method. |

test=arg (default=“mse”) | Proportion of data or number of data points in test set for shuffle method. |

nreps=arg (default=1) | Number of shuffle method repetitions. |

nfolds=arg (default=5) | Number of folds for k-fold method. |

leaveout=arg (default=2) | Number of data points left out for leave p out method. |

Random Number Options

seed=positive_integer from 0 to 2,147,483,647 | Seed the random number generator. If not specified, EViews will seed random number generator with a single integer draw from the default global random number generator. |

Type of random number generator: improved Knuth generator (“kn”), improved Mersenne Twister (“mt”), Knuth’s (1997) lagged Fibonacci generator used in EViews 4 (“kn4”) L’Ecuyer’s (1999) combined multiple recursive generator (“le”), Matsumoto and Nishimura’s (1998) Mersenne Twister used in EViews 4 (“mt4”). |

Examples

varsel(method=comb,nvars=3) y c @ x1 x2 x3 x4 x5 x6 x7 x8

performs a combinatorial search routine to search for the three variables from the set of X1, X2, ..., X8, yielding the largest R-squared in a regression of Y on a constant and those three variables.

Cross-references