Class ZipfLawAnalyzer

java.lang.Object
org.episteme.social.linguistics.ZipfLawAnalyzer

public final class ZipfLawAnalyzer extends Object
Validates Zipf's Law in a text corpus.
  • Method Details

    • analyzeFrequencies

      public static Map<Integer,Integer> analyzeFrequencies(String text)
      Analyzes word frequency distribution. Returns a map of Rank -> Frequency.
    • calculateZipfConstant

      public static Real calculateZipfConstant(int rank, int frequency)
      Checks the Zipf constant (k = rank * frequency). Ideally, this should be constant across the corpus.