autoweka

## Class Parameter

- java.lang.Object
- - autoweka.Parameter

-     public class Parameter
      extends java.lang.Object

  Captures all the data about if this parameter is categorical, numeric (and what the ranges are), and some other helper functions to get some data out of them

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `Parameter.ParamType`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `java.util.List<java.lang.String>` | `categoricalInnards` The list containing all the possible values of the parameter - only valid if type == CATEGORICAL
    `java.lang.String` | `defaultCategorical` The string containing the default categorical value - only valid if type == CATEGORICAL
    `int` | `defaultCategoricalIndex` The index containing the default categorical value - only valid if type == CATEGORICAL
    `float` | `defaultNumeric` The default numeric value - Stored as a float but will be converted to an int if needed
    `float` | `maxNumeric` The maximal numeric value - Stored as a float but will be converted to an int if needed
    `float` | `minNumeric` The minimal numeric value - Stored as a float but will be converted to an int if needed
    `java.lang.String` | `name` The name of this parameter
    `Parameter.ParamType` | `type` The type of this parameter

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `Parameter(java.lang.String line)` Creates a Parameter from a given line in a .param file.
    `Parameter(java.lang.String name, java.util.List<java.lang.String> categoricalOptions)`
    `Parameter(java.lang.String name, java.util.List<java.lang.String> categoricalOptions, java.lang.String defaultOption)`
    `Parameter(java.lang.String newName, Parameter clone)`
    `Parameter(java.lang.String name, java.lang.String categoricalOption)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.util.List<java.lang.String>` | `getDiscretization(int numPoints)` Creates a List of Strings that contain the discretization of this parameter.
    `java.lang.String` | `getRandomValue(java.util.Random rand)`
    `java.lang.String` | `toString()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### name

          public java.lang.String name

      The name of this parameter

    - #### type

          public Parameter.ParamType type

      The type of this parameter

    - #### defaultCategorical

          public java.lang.String defaultCategorical

      The string containing the default categorical value - only valid if type == CATEGORICAL

    - #### defaultCategoricalIndex

          public int defaultCategoricalIndex

      The index containing the default categorical value - only valid if type == CATEGORICAL

    - #### categoricalInnards

          public java.util.List<java.lang.String> categoricalInnards

      The list containing all the possible values of the parameter - only valid if type == CATEGORICAL

    - #### defaultNumeric

          public float defaultNumeric

      The default numeric value - Stored as a float but will be converted to an int if needed

    - #### minNumeric

          public float minNumeric

      The minimal numeric value - Stored as a float but will be converted to an int if needed

    - #### maxNumeric

          public float maxNumeric

      The maximal numeric value - Stored as a float but will be converted to an int if needed

  - ### Constructor Detail

    - #### Parameter

          public Parameter(java.lang.String line)

      Creates a Parameter from a given line in a .param file.
      Parameters:
        `line` - The line.

    - #### Parameter

          public Parameter(java.lang.String name,
                           java.lang.String categoricalOption)

    - #### Parameter

          public Parameter(java.lang.String name,
                           java.util.List<java.lang.String> categoricalOptions)

    - #### Parameter

          public Parameter(java.lang.String name,
                           java.util.List<java.lang.String> categoricalOptions,
                           java.lang.String defaultOption)

    - #### Parameter

          public Parameter(java.lang.String newName,
                           Parameter clone)

  - ### Method Detail

    - #### getDiscretization

          public java.util.List<java.lang.String> getDiscretization(int numPoints)

      Creates a List of Strings that contain the discretization of this parameter. Numeric parameters will have at most numPoints values, while Categorical parameters have all elements in their domain
      Parameters:
        `numPoints` - The number of points.
      Returns:
        The list of discretizations.

    - #### getRandomValue

          public java.lang.String getRandomValue(java.util.Random rand)

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`