类 NNge
java.lang.Object
weka.classifiers.Classifier
weka.classifiers.rules.NNge
- 所有已实现的接口:
Serializable
,Cloneable
,UpdateableClassifier
,CapabilitiesHandler
,OptionHandler
,RevisionHandler
,TechnicalInformationHandler
public class NNge
extends Classifier
implements UpdateableClassifier, OptionHandler, TechnicalInformationHandler
Nearest-neighbor-like algorithm using non-nested generalized exemplars (which are hyperrectangles that can be viewed as if-then rules). For more information, see
Brent Martin (1995). Instance-Based learning: Nearest Neighbor With Generalization. Hamilton, New Zealand.
Sylvain Roy (2002). Nearest Neighbor With Generalization. Christchurch, New Zealand. BibTeX:
Brent Martin (1995). Instance-Based learning: Nearest Neighbor With Generalization. Hamilton, New Zealand.
Sylvain Roy (2002). Nearest Neighbor With Generalization. Christchurch, New Zealand. BibTeX:
@mastersthesis{Martin1995, address = {Hamilton, New Zealand}, author = {Brent Martin}, school = {University of Waikato}, title = {Instance-Based learning: Nearest Neighbor With Generalization}, year = {1995} } @unpublished{Roy2002, address = {Christchurch, New Zealand}, author = {Sylvain Roy}, school = {University of Canterbury}, title = {Nearest Neighbor With Generalization}, year = {2002} }Valid options are:
-G <value> Number of attempts of generalisation.
-I <value> Number of folder for computing the mutual information.
- 版本:
- $Revision: 5529 $
- 作者:
- Brent Martin (bim20@cosc.canterbury.ac.nz), Sylvain Roy (sro33@student.canterbury.ac.nz)
- 另请参阅:
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明void
buildClassifier
(Instances data) Generates a classifier.double
classifyInstance
(Instance instance) Classifies a given instance.Returns default capabilities of the classifier.int
Gets the number of attempts for generalisation.int
Gets the number of folder for mutual information.String[]
Gets the current option settings for the OptionHandler.Returns the revision string.Returns an instance of a TechnicalInformation object, containing detailed information about the technical background of this class, e.g., paper reference or book this class is based on.Returns a string describing classifierReturns an enumeration of all the available options..static void
Main method for testing this class.Returns the tip text for this propertyReturns the tip text for this propertyvoid
setNumAttemptsOfGeneOption
(int newIntParameter) Sets the number of attempts for generalisation.void
setNumFoldersMIOption
(int newIntParameter) Sets the number of folder for mutual information.void
setOptions
(String[] options) Sets the OptionHandler's options using the given list.toString()
Returns a description of this classifier.void
updateClassifier
(Instance instance) Updates the classifier using the given instance.从类继承的方法 weka.classifiers.Classifier
debugTipText, distributionForInstance, forName, getDebug, makeCopies, makeCopy, setDebug
-
构造器详细资料
-
NNge
public NNge()
-
-
方法详细资料
-
globalInfo
Returns a string describing classifier- 返回:
- a description suitable for displaying in the explorer/experimenter gui
-
getTechnicalInformation
Returns an instance of a TechnicalInformation object, containing detailed information about the technical background of this class, e.g., paper reference or book this class is based on.- 指定者:
getTechnicalInformation
在接口中TechnicalInformationHandler
- 返回:
- the technical information about this class
-
getCapabilities
Returns default capabilities of the classifier.- 指定者:
getCapabilities
在接口中CapabilitiesHandler
- 覆盖:
getCapabilities
在类中Classifier
- 返回:
- the capabilities of this classifier
- 另请参阅:
-
buildClassifier
Generates a classifier. Must initialize all fields of the classifier that are not being set via options (ie. multiple calls of buildClassifier must always lead to the same result). Must not change the dataset in any way.- 指定者:
buildClassifier
在类中Classifier
- 参数:
data
- set of instances serving as training data- 抛出:
Exception
- if the classifier has not been generated successfully
-
classifyInstance
Classifies a given instance.- 覆盖:
classifyInstance
在类中Classifier
- 参数:
instance
- the instance to be classified- 返回:
- index of the predicted class as a double
- 抛出:
Exception
- if instance could not be classified successfully
-
updateClassifier
Updates the classifier using the given instance.- 指定者:
updateClassifier
在接口中UpdateableClassifier
- 参数:
instance
- the instance to include- 抛出:
Exception
- if instance could not be incorporated successfully
-
toString
Returns a description of this classifier. -
listOptions
Returns an enumeration of all the available options..- 指定者:
listOptions
在接口中OptionHandler
- 覆盖:
listOptions
在类中Classifier
- 返回:
- an enumeration of all available options.
-
setOptions
Sets the OptionHandler's options using the given list. All options will be set (or reset) during this call (i.e. incremental setting of options is not possible). Valid options are:-G <value> Number of attempts of generalisation.
-I <value> Number of folder for computing the mutual information.
- 指定者:
setOptions
在接口中OptionHandler
- 覆盖:
setOptions
在类中Classifier
- 参数:
options
- the list of options as an array of strings- 抛出:
Exception
- if an option is not supported
-
getOptions
Gets the current option settings for the OptionHandler.- 指定者:
getOptions
在接口中OptionHandler
- 覆盖:
getOptions
在类中Classifier
- 返回:
- the list of current option settings as an array of strings
-
numAttemptsOfGeneOptionTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
getNumAttemptsOfGeneOption
public int getNumAttemptsOfGeneOption()Gets the number of attempts for generalisation.- 返回:
- the value of the option G
-
setNumAttemptsOfGeneOption
public void setNumAttemptsOfGeneOption(int newIntParameter) Sets the number of attempts for generalisation.- 参数:
newIntParameter
- the new value.
-
numFoldersMIOptionTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
getNumFoldersMIOption
public int getNumFoldersMIOption()Gets the number of folder for mutual information.- 返回:
- the value of the option I
-
setNumFoldersMIOption
public void setNumFoldersMIOption(int newIntParameter) Sets the number of folder for mutual information.- 参数:
newIntParameter
- the new value.
-
getRevision
Returns the revision string.- 指定者:
getRevision
在接口中RevisionHandler
- 覆盖:
getRevision
在类中Classifier
- 返回:
- the revision
-
main
Main method for testing this class.- 参数:
argv
- should contain command line arguments for evaluation (see Evaluation).
-