Interface TermWeighting

All Superinterfaces:
AcceptingVisitor
All Known Implementing Classes:
LinearTfIdfTermWeighting, LogTfIdfTermWeighting, TfTermWeighting

public interface TermWeighting
extends AcceptingVisitor
Calculates term weights for the term-document matrix.
See Also:
TermDocumentMatrixBuilder
  • Method Summary

    Modifier and Type Method Description
    double calculateTermWeight​(int termFrequency, int documentFrequency, int documentCount)
    Calculates the weight of a term for a single document.

    Methods inherited from interface org.carrot2.attrs.AcceptingVisitor

    accept
  • Method Details

    • calculateTermWeight

      double calculateTermWeight​(int termFrequency, int documentFrequency, int documentCount)
      Calculates the weight of a term for a single document.
      Parameters:
      termFrequency - frequency of the term in the document
      documentFrequency - the number of documents containing the term
      documentCount - total number of documents