RSNNS (version 0.4-9)

SnnsRObject$train: Train a network and test it in every training iteration

Description

SnnsR low-level function to train a network and test it in every training iteration.

Usage

"train"(inputsTrain, targetsTrain=NULL, initFunc="Randomize_Weights", initFuncParams=c(1.0, -1.0), learnFunc="Std_Backpropagation", learnFuncParams=c(0.2, 0), updateFunc="Topological_Order", updateFuncParams=c(0.0), outputMethod="reg_class", maxit=100, shufflePatterns=TRUE, computeError=TRUE, inputsTest=NULL, targetsTest=NULL, pruneFunc=NULL, pruneFuncParams=NULL)

Arguments

inputsTrain
a matrix with inputs for the network
targetsTrain
the corresponding targets
initFunc
the initialization function to use
initFuncParams
the parameters for the initialization function
learnFunc
the learning function to use
learnFuncParams
the parameters for the learning function
updateFunc
the update function to use
updateFuncParams
the parameters for the update function
outputMethod
the output method of the net
maxit
maximum of iterations to learn
shufflePatterns
should the patterns be shuffled?
computeError
should the error be computed in every iteration?
inputsTest
a matrix with inputs to test the network
targetsTest
the corresponding targets for the test input
pruneFunc
the pruning function to use
pruneFuncParams
the parameters for the pruning function. Unlike the other functions, these have to be given in a named list. See the pruning demos for further explanation.

Value

a list containing: a list containing: