runCV | R Documentation |
Run a cross-validation experiment
runCV(algorithm, dataset, numFolds, cores)
algorithm |
Algorithm to be executed in the CV. It must has the parameters to be used in the executions. |
dataset |
Dataset to perform the CV. It is divided in numFolds disjoint partitions and in each iteration, one is used for test and the rest for train. |
numFolds |
Number of folds for the cross-validation procedure. |
cores |
Number of cores to execute in parallel. If it is missed, default value is 1 (sequential execution). |
Returns a list with the mean results of the numFolds executions.
#Load datasets
iris <- RKEEL::loadKeelDataset("iris")
#Create algorithm
learner_C45_C <- RKEEL::C45_C(iris, iris)
#Perform 5-folds CV
results <- RKEEL::runCV(learner_C45_C, iris, 5)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.