f_predict_pl_regression: adds predictions to learned pipelearner dataframe

Description Usage Arguments See Also Examples

View source: R/f_predict.R

Description

adds predictions to learned pipelearner dataframe

Usage

1
2
3
f_predict_pl_regression(pl, cols_id = NULL, formula = NULL,
  col_model = "fit", col_target = "target", data_test = "test",
  data_train = "train")

Arguments

pl

learned pipelearner dataframe

cols_id

character vector naming id column

formula

Default: NULL

col_model

character vector naming model column, Default: 'fit'

col_target

character vector naming target column, Default: 'target'

data_test

character vector naming test data column, Default: 'test'

data_train

character vector naming train data column, Default: 'train'#' @return dataframe

See Also

f_predict_regression_add_predictions

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
form = as.formula( 'disp~cyl+mpg')

pl = mtcars %>%
  mutate(names = row.names(.)) %>%
  pipelearner::pipelearner() %>%
  pipelearner::learn_models( rpart::rpart, form ) %>%
  pipelearner::learn_models( randomForest::randomForest, form ) %>%
  pipelearner::learn_models( e1071::svm, form ) %>%
  pipelearner::learn_models( gamlss::gamlss, form ) %>%
  pipelearner::learn() %>%
  f_predict_pl_regression( cols_id = 'names' )

erblast/oetteR documentation built on Nov. 13, 2018, 9:09 a.m.