runLearner: Run a Learning Algorithm

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/experiments.R

Description

This function can be used to run a learning algorithm whose details are stored in a learner class object.

Usage

1

Arguments

l

l is an object of class learner containing the information on the learning algorithm.

...

... represent any other parameters that are passed to the execution of the learning algorithm.

Value

The value returned by the function is the object that results from the execution of the learning algorithm.

Author(s)

Luis Torgo ltorgo@dcc.fc.up.pt

References

Torgo, L. (2010) Data Mining using R: learning with case studies, CRC Press (ISBN: 9781439810187).

http://www.dcc.fc.up.pt/~ltorgo/DataMiningWithR

See Also

learner

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Run multiple linear regression on the Swiss data set.
data(swiss)
lrn <- learner('lm',pars=list())
runLearner(lrn,Infant.Mortality ~ .,swiss)

## Not run: library(nnet)
lrn2 <- learner('nnet',pars=list(size=4,decay=0.1,linout=TRUE))
runLearner(lrn2,Infant.Mortality ~ .,swiss)

## End(Not run)

DMwR documentation built on May 1, 2019, 9:17 p.m.