public class LARSProblem extends LMProblem
Constructor and Description 

LARSProblem(LARSProblem that)
Copy constructor.

LARSProblem(Vector y,
Matrix X)
Constructs a LASSO variation of the least angel regression (LARS) problem, where an intercept
is included in the model and the predictors are normalized first.

LARSProblem(Vector y,
Matrix X,
boolean lasso)
Constructs a least angel regression (LARS) problem, where an intercept is included in the
model and the predictors are normalized first.

LARSProblem(Vector y,
Matrix X,
boolean normalized,
boolean lasso)
Constructs a least angel regression (LARS) problem, where an intercept is included in the
model.

LARSProblem(Vector y,
Matrix X,
boolean demeaned,
boolean normalized,
boolean lasso)
Constructs a Least Angel Regression (LARS) problem.

Modifier and Type  Method and Description 

boolean 
isLASSO()
Checks if the LASSO variation of LARS is used.

int 
m()
Gets the number of predictors (number of columns of X), excluding the intercept.

Vector 
XL2Norm()
Gets the L2 norms of the predictors (a vector of ones if no standardization is required).

Matrix 
XLARS()
Gets the matrix of predictors (possibly demeaned and/or scaled) to be used in LARS.

Vector 
XMean()
Gets the mean vector to be subtracted from the predictors (a vector of zeros if no intercept
is included).

Vector 
yLARS()
Gets the vector of response variable (possibly demeaned) to be used in LARS.

double 
yMean()
Gets the mean to be subtracted from the response variable (0 if no intercept is included).

A, checkInputs, intercept, invOfwAtwA, nExogenousFactors, nFactors, nObs, wA, weights, wy, X, y
public LARSProblem(Vector y, Matrix X, boolean demeaned, boolean normalized, boolean lasso)
y
 the vector of response variable (n * 1)X
 the matrix of predictors (n * m)demeaned
 an indicator of whether an intercept is included in the modelnormalized
 an indicator of whether the predictors are first normalized to have unit L2
normlasso
 an indicator of whether LASSO variation is usedpublic LARSProblem(Vector y, Matrix X, boolean normalized, boolean lasso)
y
 the vector of response variable (n * 1)X
 the matrix of predictors (n * m)normalized
 an indicator of whether the predictors are first normalized to have unit L2
normlasso
 an indicator of whether LASSO variation is usedpublic LARSProblem(Vector y, Matrix X, boolean lasso)
y
 the vector of response variable (n * 1)X
 the matrix of predictors (n * m)lasso
 an indicator of whether LASSO variation is usedpublic LARSProblem(Vector y, Matrix X)
y
 the vector of response variable (n * 1)X
 the matrix of predictors (n * m)public LARSProblem(LARSProblem that)
that
 another LeastAngelRegressionProblem
public int m()
public boolean isLASSO()
true
if the LASSO variation of LARS is usedpublic double yMean()
public Vector XMean()
public Vector XL2Norm()
public Vector yLARS()
public Matrix XLARS()
Copyright © 20102016 Numerical Method Incorporation Limited. All Rights Reserved.