step_regression: step_regression

Description Usage Arguments Value

View source: R/step_regression.R

Description

this function takes a design matrix x, and a response vector y

Usage

1
2
step_regression(x, y = NULL, labels = NULL, addIntercept = TRUE,
  mseOrder = TRUE)

Arguments

x

a matrix or variable that can be turned into a matrix via as.matrix.

y

the response vector. Defaults to NULL and redefined as the first column of x, or if that is constant, the last column of x

labels

a list of column labels. Defaults to NULL; and if NULL, redefind as the existing column names. Can reorder columns if mseOrder=FALSE

addIntercept

adds a column of ones as the first row of x to serve as an intercept. Defaults to TRUE. The 1s are added before missing ys are handled.

mseOrder

whether to order elements by their MSE if applied individually. Defaults to TRUE

Value

a matrix of residuals for each variable in x.


cmpear/StepRegression documentation built on May 20, 2020, 2:44 a.m.