com.rapidminer.operator.learner.functions.kernel
Class LibSVMModel
java.lang.Object
com.rapidminer.operator.AbstractIOObject
com.rapidminer.operator.ResultObjectAdapter
com.rapidminer.operator.AbstractModel
com.rapidminer.operator.learner.PredictionModel
com.rapidminer.operator.learner.functions.kernel.KernelModel
com.rapidminer.operator.learner.functions.kernel.LibSVMModel
- All Implemented Interfaces:
- IOObject, FormulaProvider, Model, ResultObject, Saveable, Readable, Reportable, LoggingHandler, java.io.Serializable
public class LibSVMModel
- extends KernelModel
- implements FormulaProvider
A model generated by the libsvm by Chih-Chung
Chang and Chih-Jen Lin.
- Author:
- Ingo Mierswa
- See Also:
- Serialized Form
|
Constructor Summary |
LibSVMModel(ExampleSet exampleSet,
libsvm.svm_model model,
int numberOfAttributes,
boolean confidenceForMultiClass)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
LibSVMModel
public LibSVMModel(ExampleSet exampleSet,
libsvm.svm_model model,
int numberOfAttributes,
boolean confidenceForMultiClass)
isClassificationModel
public boolean isClassificationModel()
- Specified by:
isClassificationModel in class KernelModel
getAlpha
public double getAlpha(int index)
- Specified by:
getAlpha in class KernelModel
getId
public java.lang.String getId(int index)
- Specified by:
getId in class KernelModel
getNumberOfSupportVectors
public int getNumberOfSupportVectors()
- Specified by:
getNumberOfSupportVectors in class KernelModel
getNumberOfAttributes
public int getNumberOfAttributes()
- Specified by:
getNumberOfAttributes in class KernelModel
getBias
public double getBias()
- Specified by:
getBias in class KernelModel
getSupportVector
public SupportVector getSupportVector(int index)
- Specified by:
getSupportVector in class KernelModel
getAttributeValue
public double getAttributeValue(int exampleIndex,
int attributeIndex)
- Specified by:
getAttributeValue in class KernelModel
getClassificationLabel
public java.lang.String getClassificationLabel(int index)
- Specified by:
getClassificationLabel in class KernelModel
getRegressionLabel
public double getRegressionLabel(int index)
- Specified by:
getRegressionLabel in class KernelModel
getFunctionValue
public double getFunctionValue(int index)
- Specified by:
getFunctionValue in class KernelModel
performPrediction
public ExampleSet performPrediction(ExampleSet exampleSet,
Attribute predictedLabel)
throws UserError
- Description copied from class:
PredictionModel
- Subclasses should iterate through the given example set and set the
prediction for each example. The given predicted label attribute was
already be added to the example set and should be used to set the
predicted values.
- Specified by:
performPrediction in class PredictionModel
- Throws:
UserError
toString
public java.lang.String toString()
- Description copied from class:
KernelModel
- Returns a string representation of this model.
- Specified by:
toString in interface Readable- Overrides:
toString in class KernelModel
getFormula
public java.lang.String getFormula()
- Specified by:
getFormula in interface FormulaProvider
Copyright © 2001-2009 by Rapid-I