| fit | R Documentation |
Registered learner ids currently include:
regression and classification: glm, rpart, glmnet, ranger, nnet, mlp,
densemlp, e1071_svm, randomForest, gbm, kknn, ctree, cforest,
lightgbm, xgboost, stacking, superlearner;
regression plus binary classification: gam, bart;
classification only: C50, naivebayes, fda, lda, qda;
binary classification only: adaboost;
regression plus binary classification: earth;
regression only: pls.
fit(
formula,
data,
model,
spec = NULL,
seed = NULL,
na_action = stats::na.fail,
...
)
formula |
Model formula. |
data |
Data frame. |
model |
Learner id (see |
spec |
Optional list of hyperparameters for the learner. |
seed |
Optional seed for reproducibility. |
na_action |
NA handling passed to |
... |
Additional parameters merged into |
The learner engine packages are installed with funcml, so the advertised
registry is intended to be available after a standard installation.
An object of class funcml_fit.
fit_obj <- fit(mpg ~ wt + hp, data = mtcars, model = "glm")
predict(fit_obj, newdata = mtcars[1:3, , drop = FALSE])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.