Package edu.cmu.tetrad.data
Class DiscreteDiscretizationSpec
java.lang.Object
edu.cmu.tetrad.data.DiscreteDiscretizationSpec
- All Implemented Interfaces:
DiscretizationSpec
,TetradSerializable
,Serializable
public final class DiscreteDiscretizationSpec
extends Object
implements TetradSerializable, DiscretizationSpec
Specifies how a column (continuous or discrete) should be discretized. For a discrete column the mapping is int[]
remap; for a continuous column the mapping is double[] cutoffs. The categories are the string labels for the
categories. This is just a small immutable class that columns can map to in order to remember how discretizations
were done so that the user doesn't have to keep typing in information over and over again.
- Version:
- $Id: $Id
- Author:
- josephramsey
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionDiscreteDiscretizationSpec
(int[] remap, List<String> categories) Constructor for DiscreteDiscretizationSpec. -
Method Summary
Modifier and TypeMethodDescriptionGetter for the fieldcategories
.int[]
getRemap()
Getter for the fieldremap
.static DiscreteDiscretizationSpec
Generates a simple exemplar of this class to test serialization.
-
Constructor Details
-
DiscreteDiscretizationSpec
-
-
Method Details
-
serializableInstance
Generates a simple exemplar of this class to test serialization.- Returns:
- a
DiscreteDiscretizationSpec
object
-
getCategories
-
getRemap
public int[] getRemap()Getter for the field
remap
.- Returns:
- an array of objects
-