weka.knowledgeflow.steps

## Class Associator

- java.lang.Object
- - weka.knowledgeflow.steps.BaseStep
  - - weka.knowledgeflow.steps.WekaAlgorithmWrapper
    - - weka.knowledgeflow.steps.Associator

- All Implemented Interfaces:
    java.io.Serializable, BaseStepExtender, Step

      @KFStep(name="Associator",
              category="Associations",
              toolTipText="Weka associator wrapper",
              iconPath="")
      public class Associator
      extends WekaAlgorithmWrapper

  Step that wraps a Weka associator. Handles dataSet, trainingSet and testSet incoming connections. All connections are treated the same - i.e. are used as training data.
  Version:
    $Revision: $
  Author:
    Mark Hall (mhall{[at]}pentaho{[dot]}com)
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Associator()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Associator` | `getAssociator()` Get the associator to use.
    `java.util.List<java.lang.String>` | `getIncomingConnectionTypes()` Get a list of incoming connection types that this step can accept at this time
    `java.util.List<java.lang.String>` | `getOutgoingConnectionTypes()` Get a list of outgoing connections that this step can produce at this time
    `java.lang.Class` | `getWrappedAlgorithmClass()` Get the class of the algorithm being wrapped
    `Instances` | `outputStructureForConnectionType(java.lang.String connectionName)` If possible, get the output structure for the named connection type as a header-only set of instances.
    `void` | `processIncoming(Data data)` Processes incoming data
    `void` | `setAssociator(Associator associator)` Set the associator to use.
    `void` | `setWrappedAlgorithm(java.lang.Object algo)` Set the wrapped algorithm
    `void` | `stepInit()` Initializes the step

    - ### Methods inherited from class weka.knowledgeflow.steps.WekaAlgorithmWrapper

      `getDefaultIconPath, getDefaultPackageLevelIconPath, getIconPath, getWrappedAlgorithm, globalInfo`

    - ### Methods inherited from class weka.knowledgeflow.steps.BaseStep

      `environmentSubstitute, getCustomEditorForStep, getDefaultSettings, getInteractiveViewers, getInteractiveViewersImpls, getName, getStepManager, isResourceIntensive, isStopRequested, setName, setStepIsResourceIntensive, setStepManager, setStepMustRunSingleThreaded, start, stepMustRunSingleThreaded, stop`

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

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### Associator

          public Associator()

  - ### Method Detail

    - #### getWrappedAlgorithmClass

          public java.lang.Class getWrappedAlgorithmClass()

      Get the class of the algorithm being wrapped
      Specified by:
        `getWrappedAlgorithmClass` in class `WekaAlgorithmWrapper`
      Returns:
        the class of the wrapped algorithm

    - #### setWrappedAlgorithm

          public void setWrappedAlgorithm(java.lang.Object algo)

      Set the wrapped algorithm
      Overrides:
        `setWrappedAlgorithm` in class `WekaAlgorithmWrapper`
      Parameters:
        `algo` - the wrapped algorithm

    - #### setAssociator

          @ProgrammaticProperty
          public void setAssociator(Associator associator)

      Set the associator to use. Is a convenience method - just calls setWrappedAlgorithm()
      Parameters:
        `associator` - the associator to use

    - #### getAssociator

          public Associator getAssociator()

      Get the associator to use. Is a convenience method - just calls getWrappedAlgorithm()
      Returns:
        the associator in use

    - #### stepInit

          public void stepInit()
                        throws WekaException

      Initializes the step
      Throws:
        `WekaException` - if a problem occurs

    - #### processIncoming

          public void processIncoming(Data data)
                               throws WekaException

      Processes incoming data
      Specified by:
        `processIncoming` in interface `BaseStepExtender`
      Specified by:
        `processIncoming` in interface `Step`
      Overrides:
        `processIncoming` in class `BaseStep`
      Parameters:
        `data` - the data to process
      Throws:
        `WekaException` - if a problem occurs

    - #### getIncomingConnectionTypes

          public java.util.List<java.lang.String> getIncomingConnectionTypes()

      Get a list of incoming connection types that this step can accept at this time
      Returns:
        a list of incoming connections that this step can accept

    - #### getOutgoingConnectionTypes

          public java.util.List<java.lang.String> getOutgoingConnectionTypes()

      Get a list of outgoing connections that this step can produce at this time
      Returns:
        a list of outgoing connection types

    - #### outputStructureForConnectionType

          public Instances outputStructureForConnectionType(java.lang.String connectionName)
                                                     throws WekaException

      If possible, get the output structure for the named connection type as a header-only set of instances. Can return null if the specified connection type is not representable as Instances or cannot be determined at present.
      Specified by:
        `outputStructureForConnectionType` in interface `Step`
      Overrides:
        `outputStructureForConnectionType` in class `BaseStep`
      Parameters:
        `connectionName` - the connection type to generate output structure for
      Returns:
        the output structure this step generates, or null if it can't be determined at this point in time
      Throws:
        `WekaException` - if a problem occurs