javax.datamining.supervised.classification
Interface ClassificationSettings

All Superinterfaces:
BuildSettings, MiningObject, SupervisedSettings

public interface ClassificationSettings
extends SupervisedSettings

A ClassificationSettings instance supports function settings specific to the classification mining function.

Author:
JSR-73 Java Data Mining Expert Group
See Also:
MiningObject, BuildSettings, SupervisedSettings

Method Summary
 java.lang.String getCostMatrixName()
          Returns the name of the cost matrix or null if the default cost matrix is to be used.
 java.util.Map getPriorProbabilitiesMap(java.lang.String attributeName)
          Returns the map of prior probabilities assigned by the user for the specified attribute.
 boolean getUsePriors()
          Returns true if priors are to be used for the target attribute, false otherwise.
 void setCostMatrixName(java.lang.String costMatrixName)
          Sets the name of a cost matrix that measures the cost of predictions.
 void setPriorProbabilitiesMap(java.lang.String attributeName, java.util.Map priorsMap)
          Sets the map of prior probabilties between attribute values and their prior probabilities.
 void usePriors(boolean usePriors)
          Control the use of priors for the target attribute.
 
Methods inherited from interface javax.datamining.supervised.SupervisedSettings
getTargetAttributeName, setTargetAttributeName
 
Methods inherited from interface javax.datamining.base.BuildSettings
getAlgorithmSettings, getDesiredExecutionTimeInMinutes, getLogicalAttributes, getLogicalData, getLogicalDataName, getMiningFunction, getOutlierIdentification, getOutlierTreatment, getUsage, getWeight, getWeightAttribute, setAlgorithmSettings, setDesiredExecutionTimeInMinutes, setLogicalDataName, setOutlierIdentification, setOutlierTreatment, setUsage, setWeight, setWeightAttribute, verify
 
Methods inherited from interface javax.datamining.MiningObject
getCreationDate, getCreatorInfo, getDescription, getName, getObjectIdentifier, getObjectType, setDescription
 

Method Detail

getCostMatrixName

public java.lang.String getCostMatrixName()
Returns the name of the cost matrix or null if the default cost matrix is to be used.

Returns:
String

getPriorProbabilitiesMap

public java.util.Map getPriorProbabilitiesMap(java.lang.String attributeName)
                                       throws JDMException
Returns the map of prior probabilities assigned by the user for the specified attribute. If no priors have been assigned for the attribute, returns null.

Parameters:
attributeName - The name of the attribute whose prior probabilities map is to be returned.
Returns:
Map
Throws:
JDMException

getUsePriors

public boolean getUsePriors()
Returns true if priors are to be used for the target attribute, false otherwise. By default, this method returns true meaning that priors are always used once they are set.

Returns:
boolean

setCostMatrixName

public void setCostMatrixName(java.lang.String costMatrixName)
                       throws JDMException
Sets the name of a cost matrix that measures the cost of predictions. An entry at (j, k) of a cost matrix specifies the user valuation of predicting target class j when target class k is the truth.

If a cost matrix is provded and supportsCapability for costMatrix returns true, it will be used for model build.

Parameters:
costMatrixName - The name of a CostMatrix object to be associated with classification settings.
Returns:
void
Throws:
JDMException

setPriorProbabilitiesMap

public void setPriorProbabilitiesMap(java.lang.String attributeName,
                                     java.util.Map priorsMap)
                              throws JDMException
Sets the map of prior probabilties between attribute values and their prior probabilities. The key for the map is the attribute value whose type can be one of integer, double, and string.

An exception is thrown if attributeName is not found. An exception is thrown if any object type in it is invalid in the map.

Parameters:
attributeName - The name of the attribute whose prior probabilities are to be set.
priorsMap - A map between attribute values and their prior probabilities.
Returns:
void
Throws:
JDMException

usePriors

public void usePriors(boolean usePriors)
Control the use of priors for the target attribute. Priors are ignored if false, and priors are used if true. By default, the priors will be used once they are set.

Parameters:
usePriors -
Returns:
void