gov.llnl.ontology.wordnet.sim
Class WuPalmerSimilarity

java.lang.Object
  extended by gov.llnl.ontology.wordnet.sim.WuPalmerSimilarity
All Implemented Interfaces:
SynsetSimilarity

public class WuPalmerSimilarity
extends Object
implements SynsetSimilarity

Implements the Wu-Palmer Similarity. This measure scores Synsets based on the depth of the two Synsets in the taxonomy and their lowest common subsumer, i.e. the deepest node in the tree that is a hypernym of both Synsets. This lowest common subsumer is not always the same as the shared hypernym that forms the shortest path between the two Synsets. When there are multiple subsumers, the subsumer with the longest path to the root of the taxonomy is selected.

Author:
Keith Stevens

Constructor Summary
WuPalmerSimilarity()
           
 
Method Summary
 double similarity(Synset synset1, Synset synset2)
          Returns the similarity between synset1 and synset2 based on how they are connected in the word net hierarchy.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WuPalmerSimilarity

public WuPalmerSimilarity()
Method Detail

similarity

public double similarity(Synset synset1,
                         Synset synset2)
Returns the similarity between synset1 and synset2 based on how they are connected in the word net hierarchy.

Specified by:
similarity in interface SynsetSimilarity


Copyright © 2010-2011. All Rights Reserved.