Enum Class RoccaContourDataBlock.PosSweepIndx
- All Implemented Interfaces:
Serializable
,Comparable<RoccaContourDataBlock.PosSweepIndx>
,Constable
- Enclosing class:
RoccaContourDataBlock
The WEKA random forest classifier code stores all attributes as double values. For nominal attributes, WEKA assumes that the stored value refers to the INDEX of the corresponding value. For example, the FREQBEGUP attribute can be true (yes, the slope is positive) or false (no, the slope is not positive). The training dataset uses the values "0" to indicate false, and "1" to indicate true. When the classifier is created, it stores these nominal values in an array of length 2, with array index 0 being 0 (false), and index 1 being 1 (true). When an instance gets passed to the classifier for classification, it assumes that the value stored in the attribute refers to the index position (0 or 1), NOT the actual nominal value (0/false or 1/true). So this enum field is used to map the nominal false-true values to the corresponding array indices used to train the classifier.
IMPORTANT NOTE:
Right now, this doesn't matter because the potential values 0 and 1 coincidentally match the array indices 0 and 1. But if the order or potential values of the nominal attribute ever change, this enum MUST CHANGE TO MATCH. For example, if false-true are ever reordered in the training set to true-false, the SweepIndx enum needs to be changed to true=0 and false=1. Similarly, if 'maybe' is added to the list as false-maybe-true (using the values -1, 0, and 1 respectively), SweepIndx needs to be changed to false=0, maybe=1 and true=2.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
getIndx()
Returns the enum constant of this class with the specified name.static RoccaContourDataBlock.PosSweepIndx[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Enum Constant Details
-
FALSE
-
TRUE
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
getIndx
public int getIndx()
-