Documentation of 'smile.nlp.collocation.BigramCollocation' Java class
BigramCollocation
smile.nlp.collocation

Class BigramCollocation

  • All Implemented Interfaces:
    java.lang.Comparable<BigramCollocation>


    public class BigramCollocation
    extends java.lang.Object
    implements java.lang.Comparable<BigramCollocation>
    Collocations are expressions of multiple words which commonly co-occur. A bigram collocation is a pair of words w1 w2 that appear together with statistically significance.
    • Constructor Summary

      Constructors 
      Constructor and Description
      BigramCollocation(java.lang.String w1, java.lang.String w2, int frequency, double score)
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      int compareTo(BigramCollocation o) 
      boolean equals(java.lang.Object obj) 
      int frequency()
      Returns the frequency of bigram in the corpus.
      int hashCode() 
      double score()
      Returns the chi-square statistical score of the collocation.
      java.lang.String toString() 
      java.lang.String w1()
      Returns the first word of bigram.
      java.lang.String w2()
      Returns the second word of bigram.
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • BigramCollocation

        public BigramCollocation(java.lang.String w1,
                                 java.lang.String w2,
                                 int frequency,
                                 double score)
        Constructor.
        Parameters:
        w1 - the first word of bigram.
        w2 - the second word of bigram.
        frequency - the frequency of bigram in the corpus.
        score - the chi-square statistical score of collocation in a corpus.
    • Method Detail

      • w1

        public java.lang.String w1()
        Returns the first word of bigram.
      • w2

        public java.lang.String w2()
        Returns the second word of bigram.
      • frequency

        public int frequency()
        Returns the frequency of bigram in the corpus.
      • score

        public double score()
        Returns the chi-square statistical score of the collocation.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object

DataMelt 3.0 © DataMelt by jWork.ORG

Ads help maintain this website.