run,bootstrap,DatasetExperiment,metric-method {structToolbox} | R Documentation

## Runs an iterator, applying the chosen model multiple times.

### Description

Running an iterator will apply the iterator a number of times to a DatasetExperiment. For example, in cross-validation the same model is applied multiple times to the same data, splitting it into training and test sets. The input metric object can be calculated and collected for each iteration as an output.

### Usage

    ## S4 method for signature 'bootstrap,DatasetExperiment,metric'
    run(I, D, MET = NULL)

    ## S4 method for signature 'forward_selection_byrank,DatasetExperiment,metric'
    run(I, D, MET)

    ## S4 method for signature 'grid_search_1d,DatasetExperiment,metric'
    run(I, D, MET)

    ## S4 method for signature 'kfold_xval,DatasetExperiment,metric'
    run(I, D, MET = NULL)

    ## S4 method for signature 'permutation_test,DatasetExperiment,metric'
    run(I, D, MET = NULL)

    ## S4 method for signature 'permute_sample_order,DatasetExperiment,metric'
    run(I, D, MET)

### Arguments

`I` | an iterator object
`D` | a DatasetExperiment object
`MET` | a metric object

### Value

Modified iterator object

### Examples

    D = iris_DatasetExperiment() # get some data
    MET = metric()  # use a metric
    I = example_iterator() # initialise iterator
    models(I) = example_model() # set the model
    I = run(I,D,MET) # run

[Package structToolbox version 1.0.1 Index]