Container for data in form of [consideration_values][decision], where consideration values are [float, float,...,float] and decision is TDecisionType. USe it for training the decision tree.
More...
|
bool | MoveFromOther (Dataset< TDecisionType > sourceDataset) |
| Moves samples from another dataset to the dataset this function was called on. It performs a basic check whether ConsiderationTypes are compatible between the two dataset. Warning: If succeeded, this will erase the sourceDataset. More...
|
|
bool | CopyFromOther (in Dataset< TDecisionType > sourceDataset) |
| Adds samples from another dataset to the dataset this function was called on. It performs a basic check whether ConsiderationTypes are compatible between the two dataset. More...
|
|
| Dataset (params DecisionConsiderationType[] considerationTypes) |
| Creates a new dataset. More...
|
|
double | ValidateBinary (DecisionNode< TDecisionType > rootNode) |
| Tests a decision tree (represented by the root node) against a dataset. Returns the accuracy of decision predictions vs. decisions that are in the dataset. More...
|
|
void | WriteToFile (IDecisionStringSerializer< TDecisionType > decisionSerializer, StreamWriter writer) |
| Use this method to serialize content of the Dataset to the file. More...
|
|
void | ReadFromFile (IDecisionStringSerializer< TDecisionType > decisionSerializer, StreamReader reader) |
| Use this method to read the Dataset content from a file. More...
|
|
Container for data in form of [consideration_values][decision], where consideration values are [float, float,...,float] and decision is TDecisionType. USe it for training the decision tree.
- Template Parameters
-
◆ Dataset()
Creates a new dataset.
- Parameters
-
considerationTypes | Data type {NUMERIC, NOMINAL} for the respective columns in the dataset. |
◆ CopyFromOther()
Adds samples from another dataset to the dataset this function was called on. It performs a basic check whether ConsiderationTypes are compatible between the two dataset.
- Parameters
-
sourceDataset | The dataset to copy samples from. |
- Returns
- TRUE: if samples been succesfully added. FALSE: when ConsiderationTypes are incompatible and therefore the data have not been added.
◆ MoveFromOther()
Moves samples from another dataset to the dataset this function was called on. It performs a basic check whether ConsiderationTypes are compatible between the two dataset. Warning: If succeeded, this will erase the sourceDataset.
- Parameters
-
sourceDataset | The dataset to move samples from. |
- Returns
- TRUE: if samples been succesfully moved. FALSE: when ConsiderationTypes are incompatible and therefore the data have not been moved.
◆ ReadFromFile()
Use this method to read the Dataset content from a file.
- Parameters
-
decisionSerializer | Provide instance of a class responsible for serialization of the decision type to string. The decision is in each dataset sample. |
reader | A standard .NET StreamReader object |
◆ ValidateBinary()
Tests a decision tree (represented by the root node) against a dataset. Returns the accuracy of decision predictions vs. decisions that are in the dataset.
- Returns
- Prediction accuracy.
◆ WriteToFile()
Use this method to serialize content of the Dataset to the file.
- Parameters
-
decisionSerializer | Provide instance of a class responsible for serialization of the decision type to string. The decision is in each dataset sample. |
writer | A standard .NET StreamWriter object |
◆ ConsiderationTypes
Gets types of the respective consideration, in order of appearance. The types are either NUMERIC or NOMINAL.
◆ DecisionVariablesCount
The number of measures (also know as considerations / decisions / columns in dataset).
◆ Samples
The documentation for this class was generated from the following file:
- GrailSimulatedGames/source/SimulatedGames/OfflineLearning/Dataset.cs