public class RepeatedCrossValidationResults
extends java.lang.Object
| Constructor | Description |
|---|---|
RepeatedCrossValidationResults() |
Sole constructor
|
| Modifier and Type | Method | Description |
|---|---|---|
void |
appendCrossValidationSeedToFile(java.lang.String filePath,
int crossValidationIndex) |
Appends seed of cross-validation with a given index to the file with a given path.
|
boolean |
crossValidationIsComplete(int crossValidationIndex) |
Tells if cross-validation with given index is complete (i.e., concerns all folds)
|
boolean |
crossValidationIsRegistered(int crossValidationIndex) |
Checks whether the cross-validation with a given index is registered within these results
|
long |
getCrossValidationSeed(int crossValidationIndex) |
Gets seed of the cross-validation with a given index
|
int |
getFoldsCount(int crossValidationIndex) |
Gets the number of folds performed in the cross-validation with a given index
|
int |
getPathsCount() |
Gets the number of execution paths of each cross-validation's fold
|
java.util.HashSet<java.lang.Integer> |
getRegisteredCrossValidationIndices() |
Gets the numbers of cross-validations registered within these results
|
int |
getRegisteredCrossValidationsCount() |
Gets the number of cross-validations registered within these results
|
void |
registerCrossValidation(int crossValidationIndex) |
Registers cross-validation with a given index within these results.
|
void |
registerIncompleteCrossValidation(int crossValidationIndex) |
Registers incomplete cross-validation with a given index within these results.
|
void |
setCrossValidationFoldPaths(int crossValidationIndex,
int foldIndex,
CrossValidationFoldPaths crossValidationFoldPaths) |
Stores cross-validation fold paths for a cross-validation and its fold with given indices.
|
void |
setCrossValidationSeed(int crossValidationIndex,
long seed) |
Stores seed of the cross-validation with a given index
|
boolean |
writePathAverages(java.lang.String filePath,
int numberOfAllCrossValidations,
java.lang.String lineOfHeadings) |
Calculates average errors for each registered complete cross-validation and for each execution path.
|
public RepeatedCrossValidationResults()
public void registerCrossValidation(int crossValidationIndex)
crossValidationIndex - cross-validation indexpublic void registerIncompleteCrossValidation(int crossValidationIndex)
crossValidationIndex - cross-validation indexpublic boolean crossValidationIsRegistered(int crossValidationIndex)
crossValidationIndex - cross-validation indextrue if the cross-validation with a given index is registered within these results, false otherwisepublic long getCrossValidationSeed(int crossValidationIndex)
crossValidationIndex - cross-validation indexValueNotFoundException - when the cross-validation with a given index is not registered within these results
or when there is no seed stored for the cross-validation with a given indexpublic void setCrossValidationSeed(int crossValidationIndex,
long seed)
crossValidationIndex - cross-validation indexseed - seed of the cross-validation with a given indexValueNotFoundException - when the cross-validation with a given index is not registered within these resultspublic void setCrossValidationFoldPaths(int crossValidationIndex,
int foldIndex,
CrossValidationFoldPaths crossValidationFoldPaths)
crossValidationIndex - index of considered cross-validationfoldIndex - index of considered fold within considered cross-validationcrossValidationFoldPaths - cross-validation fold paths to storeValueNotFoundException - when the cross-validation with a given index is not registered within these resultspublic int getRegisteredCrossValidationsCount()
public java.util.HashSet<java.lang.Integer> getRegisteredCrossValidationIndices()
public int getFoldsCount(int crossValidationIndex)
crossValidationIndex - index of the considered cross-validation-1 if the cross-validation with a given index has not been performed yetValueNotFoundException - when the cross-validation with a given index is not registered within these resultspublic int getPathsCount()
public void appendCrossValidationSeedToFile(java.lang.String filePath,
int crossValidationIndex)
throws java.io.IOException
filePath - path to a file where cross-validation seed should be appendedcrossValidationIndex - index of considered cross-validationjava.io.IOException - when file with a given path cannot be opened for writeValueNotFoundException - when the cross-validation with a given index is not registered within these results
or when there is no seed stored for the cross-validation with a given indexpublic boolean writePathAverages(java.lang.String filePath,
int numberOfAllCrossValidations,
java.lang.String lineOfHeadings)
throws java.io.IOException
filePath - path to a file where averages should be savednumberOfAllCrossValidations - number of all cross-validations performed in a ranking experimentlineOfHeadings - line of headings printed to file, if not nulltrue if path averages has been saved to disk, false otherwisejava.io.IOException - when the file with a given path cannot be opened for writeInvalidValueException - when the number of cross-validations registered within these results
is greater than a given number of all cross-validations in a ranking experimentpublic boolean crossValidationIsComplete(int crossValidationIndex)
crossValidationIndex - cross-validation indextrue if the cross-validation with given index is complete, false otherwiseValueNotFoundException - when the cross-validation with a given index is not registered within these results