MOA_regressor: Create a MOA regressor

View source: R/Regression.R

MOA_regressorR Documentation

Create a MOA regressor

Description

Create a MOA regressor

Usage

MOA_regressor(model, control = NULL, ...)

Arguments

model

character string with a model. E.g. AMRulesRegressor, FadingTargetMean, FIMTDD, ORTO, Perceptron, RandomRules, SGD, TargetMean, ... The list of known models can be obtained by typing RMOA:::.moaknownmodels. See the examples and MOAoptions.

control

an object of class MOAmodelOptions as obtained by calling MOAoptions

...

options of parameters passed on to MOAoptions, in case control is left to NULL. Ignored if control is supplied

Value

An object of class MOA_regressor

See Also

MOAoptions

Examples

mymodel <- MOA_regressor(model = "FIMTDD")
mymodel
data(iris)
iris <- factorise(iris)
irisdatastream <- datastream_dataframe(data=iris)
## Train the model
mytrainedmodel <- trainMOA(model = mymodel, 
 Sepal.Length ~ Petal.Length + Species, data = irisdatastream)
mytrainedmodel$model

summary(lm(Sepal.Length ~ Petal.Length + Species, data = iris))
predict(mytrainedmodel, newdata=iris)

RMOA documentation built on July 18, 2022, 1:05 a.m.