Description Usage Arguments Value Note Author(s) See Also Examples
View source: R/CrossValidation.R
Performs a cross-validation using the specified
algorithms. If package parallel is loaded the
cross-validation will be performed in parallel. If the
parallel package is loaded but a parallel
cross-validation is not wanted parallel
can be set
to FALSE
. If parallel cross-validation is desired
the number of cores can be choosen by using the
cores
parameter.
1 2 |
x |
a p x n matrix of expression measurements with p samples and n genes. |
y |
a factor of length p comprising the class labels. |
theta.fit |
the method to learn a decision boundary.
Currently available are |
folds |
number of folds to perform |
repeats |
number of how often to repeat the x-fold cross-validation |
parallel |
should the cross-validation be performed
in parallel i.e. on several cpu-cores. (see also
|
cores |
specify the number of cores that should be used for parallel cross-validation. |
DEBUG |
should debugging information be plotted. Defaults to n - 1 cores. |
... |
additional parameters to theta fit. |
a list with the results of the cross-validation. See details for more information.
Parallel cross-validation can only be performed if the parallel-package was loaded prior to calling this function.
Marc Johannes JohannesMarc@gmail.com
fit.rrfe
, fit.rfe
,
fit.graph.svm
,
fit.networkBasedSVM
1 2 3 4 5 6 7 8 9 | ## Not run:
set.seed(4321)
data(example_data)
res.rfe <- crossval(x, y, DEBUG=TRUE, theta.fit=fit.rfe, folds=2, repeats=1, parallel=TRUE,
Cs=10^(-3:3))
res.rrfe <- crossval(x, y, DEBUG=TRUE, theta.fit=fit.rrfe, folds=3, repeats=1, parallel=TRUE,
Cs=10^(-3:3), mapping=mapping, Gsub=adjacency.matrix, d=1/2)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.