Usage
cv.glmreg_fit(x, y, weights, lambda=NULL, balance=TRUE,
family=c("gaussian", "binomial", "poisson", "negbin"),
nfolds=10, foldid, plot.it=TRUE, se=TRUE, trace=FALSE, ...)
Arguments
y
response y
as in glmreg
.
weights
Observation weights; defaults to 1 per observation
lambda
Optional user-supplied lambda sequence; default is
NULL
, and glmreg
chooses its own sequence
balance
for family="binomial"
only
family
response variable distribution
nfolds
number of folds >=3, default is 10
foldid
an optional vector of values between 1 and nfold
identifying what fold each observation is in. If supplied,
nfold
can be missing and will be ignored.
plot.it
a logical value, to plot the estimated log-likelihood values if TRUE
.
se
a logical value, to plot with standard errors.
trace
if TRUE
, shows cross-validation progress
...
Other arguments that can be passed to glmreg
.