meta_mod | R Documentation |
Train a meta model from the output of base learners trained using different learners (algorithms)
meta_mod(
x,
y = NULL,
x.test = NULL,
y.test = NULL,
base.mods = c("mars", "ranger"),
base.params = vector("list", length(base.mods)),
base.resample.params = setup.resample(resampler = "kfold", n.resamples = 4),
meta.mod = "gam",
meta.params = list(),
x.name = NULL,
y.name = NULL,
save.base.res = TRUE,
save.base.full = FALSE,
col = NULL,
se.lty = 3,
print.base.plot = FALSE,
print.plot = TRUE,
plot.fitted = NULL,
plot.predicted = NULL,
plot.theme = rtTheme,
question = NULL,
verbose.base.res.mods = FALSE,
verbose.base.mods = FALSE,
verbose = TRUE,
trace = 0,
base.n.cores = 1,
n.cores = rtCores,
save.mod = FALSE,
outdir = NULL,
...
)
x |
Numeric vector or matrix of features, i.e. independent variables |
y |
Numeric vector of outcome, i.e. dependent variable |
x.test |
(Optional) Numeric vector or matrix of validation set features
must have set of columns as |
y.test |
(Optional) Numeric vector of validation set outcomes |
base.mods |
Character vector: Two or more base learners. Options: select_learn |
base.params |
List of length equal to N of |
meta.mod |
String. Meta learner. Options: select_learn |
x.name |
Character: Name for predictor set. (What kind of data is it?) |
y.name |
Character: Name for outcome |
se.lty |
How to plot standard errors. If a number, it corresponds to par("lty") line types and is plotted with lines(). If "solid", a transparent polygon is plotted using polygon() |
resampler |
String. Resampling method to use. Options: "bootstrap", "kfold", "strat.boot", "strat.sub" |
This is included mainly for educational purposes.
Train a set of base learners on resamples of the training set x
Train a meta learner to map bases' validation set predictions to outcomes
Train base learners on full training set x
Use the meta learner to predict test set outcome y.test from testing set (x.test)
E.D. Gennatas
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.