Probability distribution
name =Zipf's law
type =mass
pdf_
Zipf PMF for "N" = 10 on a log-log scale. The horizontal axis is the index "k" . (Note that the function is only defined at integer values of "k". The connecting lines do not indicate continuity.)
cdf_
Zipf CMF for "N" = 10. The horizontal axis is the index "k" . (Note that the function is only defined at integer values of "k". The connecting lines do not indicate continuity.)
parameters = (real)
(integer)
support =
pdf =
cdf =
mean =
median =
mode =
variance =
skewness =
kurtosis =
entropy =
mgf =
char =
Zipf's law, an empirical law formulated using mathematical statistics, refers to the fact that many types of data studied in the physical and social sciences can be approximated with a Zipfian distribution, one of a family of related discrete power law probability distributions. The law is named after the linguist George Kingsley Zipf (pronEng|ˈzɪf) who first proposed it (Zipf 1935, 1949), though J.B. Estoup appears to have noticed the regularity before Zipf. [ Christopher D. Manning, Hinrich Schütze "Foundations of Statistical Natural Language Processing", MIT Press (1999), ISBN 978-0262133609, p. 24] .
Motivation
Zipf's law states that given some corpus of natural language utterances, the frequency of any word is inversely proportional to its rank in the frequency table. Thus the most frequent word will occur approximately twice as often as the second most frequent word, which occurs twice as often as the fourth most frequent word, etc. For example, in the Brown Corpus "the" is the most frequently occurring word, and by itself accounts for nearly 7% of all word occurrences (69971 out of slightly over 1 million). True to Zipf's Law, the second-place word "of" accounts for slightly over 3.5% of words (36411 occurrences), followed by "and" (28852). Only 135 vocabulary items are needed to account for half the Brown Corpus.
Theoretical issues
Zipf's law is most easily observed by scatterplotting the data, with the axes being log(rank order) and log(frequency). For example, "the" as described above would appear at "x" = log(1), "y" = log(69971). The data conform to Zipf's law to the extent that the plotted points appear to fall along a single line segment.
Formally, let:
* "N" be the number of elements;
* "k" be their rank;
* "s" be the value of the exponent characterizing the distribution.Zipf's law then predicts that out of a population of "N" elements, the frequency of elements of rank "k", "f"("k";"s","N"), is:
:
In the example of the frequency of words in the English language, "N" is the number of words in the English language and, if we use the classic version of Zipf's law, the exponent "s" is 1. "f"("k"; "s","N") will then be the fraction of the time the "k"th most common word occurs.
It is easily seen that the distribution is normalized, i.e., the predicted frequencies sum to 1:
:
The law may also be written:
:
where "HN,s" is the "N"th generalized harmonic number.
The simplest case of Zipf's law is a "1/"f" function". Given a set of Zipfian distributed frequencies, sorted from most common to least common, the second most common frequency will occur ½ as often as the first. The third most common frequency will occur 1/3 as often as the first. The "n"th most common frequency will occur 1/"n" as often as the first. However, this cannot hold exactly, because items must occur an integer number of times: there cannot be 2.5 occurrences of a word. Nevertheless, over fairly wide ranges, and to a fairly good approximation, many natural phenomena obey Zipf's law.
Mathematically, it is impossible for the classic version of Zipf's law to hold exactly if there are infinitely many words in a language, since the sum of all relative frequencies in the denominator above is equal to the harmonic series and therefore:
:
In English, the frequencies of the approximately 1000 most-frequently-used words are approximately proportional to 1/"n""s" where "s" is just slightly more than one. Fact|date=June 2007
As long as the exponent "s" exceeds 1, it is possible for such a law to hold with infinitely many words, since if "s" > 1 then: