Usage
varAdd1(x, grp, vin=NULL, scope=1:ncol(x), k=0)
varDrop1(x, grp, vin=1:ncol(x), k=0)
varStep(x, grp, scope, k, kf=k/2, direction=c("both",
"forward","backward"))Arguments
x
data matrix/frame. Columns are variables to select from.
grp
grouping indicator of observations.
vin
which variables (i.e., columns of x) already in model. It defines the initial model.
scope
which variables (i.e., columns of x) to select from.
k
entry/stay value in backward stepwise.
kf
entry/stay value in forward stepwise.
direction
forward selection, backward elimination or both stepwise.