net.ontopia.topicmaps.classify
Class FrequencyAnalyzer
java.lang.Object
net.ontopia.topicmaps.classify.FrequencyAnalyzer
- All Implemented Interfaces:
- TermAnalyzerIF
public class FrequencyAnalyzer
- extends java.lang.Object
- implements TermAnalyzerIF
INTERNAL: A frequency table giving the frequency with which a
particular word is used in a particular language.
Field Summary |
protected gnu.trove.TObjectDoubleHashMap |
freqs
|
Constructor Summary |
FrequencyAnalyzer(java.io.File file)
INTERNAL: Loads a frequency table from a file. |
FrequencyAnalyzer(java.lang.String filename)
INTERNAL: Loads a frequency table as a resource. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
freqs
protected gnu.trove.TObjectDoubleHashMap freqs
FrequencyAnalyzer
public FrequencyAnalyzer(java.lang.String filename)
- INTERNAL: Loads a frequency table as a resource. The format is a
plain text file where each line is 'term;factor' where factor is
a real in the range 0-1. The score of the term after
classification is multiplied with the factor. Thus, a factor of
0.5 will reduce the score of the term by half.
FrequencyAnalyzer
public FrequencyAnalyzer(java.io.File file)
- INTERNAL: Loads a frequency table from a file. The format is a
plain text file where each line is 'term;factor' where factor is
a real in the range 0-1. The score of the term after
classification is multiplied with the factor. Thus, a factor of
0.5 will reduce the score of the term by half.
analyzeTerm
public void analyzeTerm(Term term)
- Specified by:
analyzeTerm
in interface TermAnalyzerIF
startAnalysis
public void startAnalysis(TermDatabase tdb)
- Specified by:
startAnalysis
in interface TermAnalyzerIF
endAnalysis
public void endAnalysis()
- Specified by:
endAnalysis
in interface TermAnalyzerIF
Copyright © 2000-2012 Ontopia.