idrbag {isodistrreg} | R Documentation |
Compute IDR predictions with (su)bagging
Description
Computes IDR predictions with bootstrap aggregating (bagging) or subsample aggregation (subagging).
Usage
idrbag(y, X, groups = setNames(rep(1, ncol(X)), colnames(X)), orders =
c("comp" = 1), stoch = "sd", pars = osqpSettings(verbose = FALSE, eps_abs =
1e-5, eps_rel = 1e-5, max_iter = 10000L), progress = TRUE, newdata,
digits = 3, interpolation = "linear", b, p, replace = FALSE, grid = NULL)
Arguments
y |
numeric vector (the response variable). |
X |
data frame of numeric or ordered factor variables (the regression covariates). |
groups |
named vector of length |
orders |
named vector giving for each group in |
stoch |
stochastic order constraint used for estimation. Default is
|
pars |
parameters for quadratic programming optimization (only relevant
if |
progress |
display progressbar ( |
newdata |
|
digits |
number of decimal places for the predictive CDF. |
interpolation |
interpolation method for univariate data. Default is
|
b |
number of (su)bagging samples. |
p |
size of (su)bagging samples relative to training data. |
replace |
draw samples with ( |
grid |
grid on which the predictive CDFs are evaluated. Default are
the unique values of |
Details
This function draws b
times a random subsample of size
ceiling(nrow(X)*p)
) from the training data, fits IDR to each
subsample, computes predictions for the new data supplied in newdata
,
and averages the predictions derived from the b
subsamples. There are
no default values for b
and p
.
Value
A list of predictions, see predict.idrfit
.