Learn R Programming

crtests (version 0.2.1)

regression_model: Fit a regression model Generic function for fitting a regression model

Description

Fit a regression model Generic function for fitting a regression model

Usage

regression_model(method, formula, training_data, ...)
"regression_model"(method, formula, training_data, ...)

Arguments

method
The regression method to use
formula
An object of class 'formula', used to fit a model to the data
training_data
Train data used to fit the model
...
Further arguments

Value

model The fitted model

Methods (by class)

  • default: Default function for fitting a regression model This gets the method and calls it using formula and data