public class ClassStratiFileAssigner extends java.lang.Object implements IStratiFileAssigner
| Constructor and Description |
|---|
ClassStratiFileAssigner()
Constructor without a given target attribute.
|
ClassStratiFileAssigner(int targetAttribute)
Constructor with a given target attribute.
|
| Modifier and Type | Method and Description |
|---|---|
void |
assignDatapoint(java.lang.String datapoint)
Select the suitable stratum for a datapoint and write it into the
corresponding temporary file.
|
java.util.Map<java.lang.String,java.lang.Integer> |
getAllCreatedStrati()
Get the used strati temporary files and the amount of datapoints inside of
it.
|
void |
setArffHeader(java.lang.String arffHeader)
Set the header of the original ARFF input file.
|
void |
setTempFileHandler(ai.libs.jaicore.basic.TempFileHandler tempFileHandler)
Set the temporary file handler, which will be used to manage the temporary
files for the strati.
|
public ClassStratiFileAssigner(int targetAttribute)
targetAttribute - Index of the target attribute.public ClassStratiFileAssigner()
public void setTempFileHandler(ai.libs.jaicore.basic.TempFileHandler tempFileHandler)
IStratiFileAssignersetTempFileHandler in interface IStratiFileAssignertempFileHandler - Temporary File Handler to manage the files.public void setArffHeader(java.lang.String arffHeader)
IStratiFileAssignersetArffHeader in interface IStratiFileAssignerarffHeader - ARFF header lines as a string.public void assignDatapoint(java.lang.String datapoint)
throws ai.libs.jaicore.basic.algorithm.exceptions.AlgorithmException
IStratiFileAssignerassignDatapoint in interface IStratiFileAssignerdatapoint - String representation of the datapoint taken from the input
file.ai.libs.jaicore.basic.algorithm.exceptions.AlgorithmException - The datapoint representation was invalid or it
could not be assigned to a stratum.public java.util.Map<java.lang.String,java.lang.Integer> getAllCreatedStrati()
IStratiFileAssignergetAllCreatedStrati in interface IStratiFileAssigner