Package 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 Description Associator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AssociatorgetAssociator()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 timejava.util.List<java.lang.String>getOutgoingConnectionTypes()Get a list of outgoing connections that this step can produce at this timejava.lang.ClassgetWrappedAlgorithmClass()Get the class of the algorithm being wrappedInstancesoutputStructureForConnectionType(java.lang.String connectionName)If possible, get the output structure for the named connection type as a header-only set of instances.voidprocessIncoming(Data data)Processes incoming datavoidsetAssociator(Associator associator)Set the associator to use.voidsetWrappedAlgorithm(java.lang.Object algo)Set the wrapped algorithmvoidstepInit()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, outputStructureForConnectionType, setName, setStepIsResourceIntensive, setStepManager, setStepMustRunSingleThreaded, start, stepMustRunSingleThreaded, stop
-
-
-
-
Method Detail
-
getWrappedAlgorithmClass
public java.lang.Class getWrappedAlgorithmClass()
Get the class of the algorithm being wrapped- Specified by:
getWrappedAlgorithmClassin classWekaAlgorithmWrapper- Returns:
- the class of the wrapped algorithm
-
setWrappedAlgorithm
public void setWrappedAlgorithm(java.lang.Object algo)
Set the wrapped algorithm- Overrides:
setWrappedAlgorithmin classWekaAlgorithmWrapper- 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 WekaExceptionInitializes the step- Throws:
WekaException- if a problem occurs
-
processIncoming
public void processIncoming(Data data) throws WekaException
Processes incoming data- Specified by:
processIncomingin interfaceBaseStepExtender- Specified by:
processIncomingin interfaceStep- Overrides:
processIncomingin classBaseStep- 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:
outputStructureForConnectionTypein interfaceStep- Overrides:
outputStructureForConnectionTypein classBaseStep- 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
-
-