@KFStep(name="CrossValidationFoldMaker", category="Evaluation", toolTipText="A Step that creates stratified cross-validation folds from incoming data", iconPath="weka/gui/knowledgeflow/icons/CrossValidationFoldMaker.gif") public class CrossValidationFoldMaker extends BaseStep
| Constructor and Description |
|---|
CrossValidationFoldMaker() |
| Modifier and Type | Method and Description |
|---|---|
List<String> |
getIncomingConnectionTypes()
Get a list of incoming connection types that this step can accept.
|
String |
getNumFolds()
Get the number of folds to create
|
List<String> |
getOutgoingConnectionTypes()
Get a list of outgoing connection types that this step can produce.
|
boolean |
getPreserveOrder()
Get whether to preserve the order of the input instances when creatinbg
the folds
|
String |
getSeed()
Get the random seed
|
Instances |
outputStructureForConnectionType(String connectionName)
If possible, get the output structure for the named connection type as a
header-only set of instances.
|
void |
processIncoming(Data data)
Process an incoming data payload (if the step accepts incoming connections)
|
void |
setNumFolds(String folds)
Set the number of folds to create
|
void |
setPreserveOrder(boolean preserve)
Set whether to preserve the order of the input instances when creatinbg
the folds
|
void |
setSeed(String seed)
Set the random seed to use
|
void |
stepInit()
Initialize the step.
|
environmentSubstitute, getCustomEditorForStep, getDefaultSettings, getInteractiveViewers, getInteractiveViewersImpls, getName, getStepManager, globalInfo, isResourceIntensive, isStopRequested, setName, setStepIsResourceIntensive, setStepManager, start, stop@OptionMetadata(displayName="Number of folds", description="THe number of folds to create", displayOrder=0) public void setNumFolds(String folds)
folds - the number of folds to createpublic String getNumFolds()
@OptionMetadata(displayName="Preserve instances order", description="Preserve the order of instances rather than randomly shuffling", displayOrder=1) public void setPreserveOrder(boolean preserve)
preserve - true to preserve the orderpublic boolean getPreserveOrder()
@OptionMetadata(displayName="Random seed", description="The random seed to use for shuffling", displayOrder=3) public void setSeed(String seed)
seed - the random seed to usepublic String getSeed()
public void stepInit()
throws WekaException
WekaException - if a problem occurs during initializationpublic void processIncoming(Data data) throws WekaException
processIncoming in interface BaseStepExtenderprocessIncoming in interface StepprocessIncoming in class BaseStepdata - the payload to processWekaException - if a problem occurspublic List<String> getIncomingConnectionTypes()
public List<String> getOutgoingConnectionTypes()
public Instances outputStructureForConnectionType(String connectionName) throws WekaException
outputStructureForConnectionType in interface StepoutputStructureForConnectionType in class BaseStepconnectionName - the name of the connection type to get the output
structure forWekaException - if a problem occursCopyright © 2016 University of Waikato, Hamilton, NZ. All Rights Reserved.