org.encog.ml.model
public class EncogModel extends Object
Constructor and Description |
---|
EncogModel(VersatileMLDataSet theDataset)
Construct a model for the specified dataset.
|
Modifier and Type | Method and Description |
---|---|
double |
calculateError(MLMethod method,
MLDataSet data)
Calculate the error for the given method and dataset.
|
MLMethod |
createMethod()
Create the selected method.
|
MLMethod |
crossvalidate(int k,
boolean shuffle)
Crossvalidate and fit.
|
VersatileMLDataSet |
getDataset() |
List<ColumnDefinition> |
getInputFeatures() |
Map<String,MethodConfig> |
getMethodConfigurations() |
List<ColumnDefinition> |
getPredictedFeatures() |
StatusReportable |
getReport() |
MatrixMLDataSet |
getTrainingDataset() |
MatrixMLDataSet |
getValidationDataset() |
void |
holdBackValidation(double validationPercent,
boolean shuffle,
int seed)
Specify a validation set to hold back.
|
void |
selectMethod(VersatileMLDataSet dataset,
String methodType)
Select the method to create.
|
void |
selectMethod(VersatileMLDataSet dataset,
String methodType,
String methodArgs,
String trainingType,
String trainingArgs)
Select the method to use.
|
void |
selectTraining(VersatileMLDataSet dataset,
String trainingType,
String trainingArgs)
Select the training to use.
|
void |
selectTrainingType(VersatileMLDataSet dataset)
Select the training type.
|
void |
setReport(StatusReportable report) |
void |
setTrainingDataset(MatrixMLDataSet trainingDataset) |
void |
setValidationDataset(MatrixMLDataSet validationDataset) |
public EncogModel(VersatileMLDataSet theDataset)
theDataset
- The dataset.public VersatileMLDataSet getDataset()
public List<ColumnDefinition> getInputFeatures()
public List<ColumnDefinition> getPredictedFeatures()
public void holdBackValidation(double validationPercent, boolean shuffle, int seed)
validationPercent
- The percent to use for validation.shuffle
- True to shuffle.seed
- The seed for random generation.public double calculateError(MLMethod method, MLDataSet data)
method
- The method to use.data
- The data to use.public MLMethod crossvalidate(int k, boolean shuffle)
k
- The number of folds.shuffle
- True if we should shuffle.public MatrixMLDataSet getTrainingDataset()
public void setTrainingDataset(MatrixMLDataSet trainingDataset)
trainingDataset
- the trainingDataset to setpublic MatrixMLDataSet getValidationDataset()
public void setValidationDataset(MatrixMLDataSet validationDataset)
validationDataset
- the validationDataset to setpublic void selectMethod(VersatileMLDataSet dataset, String methodType, String methodArgs, String trainingType, String trainingArgs)
dataset
- The dataset.methodType
- The type of method.methodArgs
- The method arguments.trainingType
- The training type.trainingArgs
- The training arguments.public MLMethod createMethod()
public void selectMethod(VersatileMLDataSet dataset, String methodType)
dataset
- The dataset.methodType
- The method type.public void selectTrainingType(VersatileMLDataSet dataset)
dataset
- The dataset.public void selectTraining(VersatileMLDataSet dataset, String trainingType, String trainingArgs)
dataset
- The dataset.trainingType
- The type of training.trainingArgs
- The training arguments.public Map<String,MethodConfig> getMethodConfigurations()
public StatusReportable getReport()
public void setReport(StatusReportable report)
report
- the report to setCopyright © 2014. All Rights Reserved.