|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjcolibri.test.test13.similarity.AverageMultipleTextValues
public class AverageMultipleTextValues
This function converts the text value of an attribute into several numeric values and calculates its average. Then it computes the interval difference between query and case.
Example:
Query attribute: 2.0, 4.0 -> Average = 3.0
Case attribute: 5.0, 9.0, 4.0 -> Average = 6.0
If interval param is 9.0 computed similarity equals: 0.33
Constructor Summary | |
---|---|
AverageMultipleTextValues(double interval)
Creates a new instance of MaxString |
Method Summary | |
---|---|
double |
compute(java.lang.Object caseObject,
java.lang.Object queryObject)
Computes the similarity between two objects |
boolean |
isApplicable(java.lang.Object o1,
java.lang.Object o2)
Applicable to String |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AverageMultipleTextValues(double interval)
Method Detail |
---|
public double compute(java.lang.Object caseObject, java.lang.Object queryObject) throws NoApplicableSimilarityFunctionException
LocalSimilarityFunction
compute
in interface LocalSimilarityFunction
caseObject
- object of the casequeryObject
- object of the query
NoApplicableSimilarityFunctionException
public boolean isApplicable(java.lang.Object o1, java.lang.Object o2)
isApplicable
in interface LocalSimilarityFunction
|
GAIA - Group for Artificial Intelligence Applications http://gaia.fdi.ucm.es |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |