document frequency (docf)

The document frequency is the number of documents in which the token or phrase appears.

If the corpus has 100 documents and 2 documents contain the word city:
document number 7 contains 17 instances of city,
document number 31 contains 6 instances of city,

the document frequency of city is 2, because 2 documents contain the word.

It is not affected by the number of documents in the corpus contains or by the total frequency of the token.

The document frequency can be better suited for comparison in situations when the corpus contains a small number of documents with an extremely high frequency of particular words.

Relative document frequency (also relative DOCF) is the percentage of documents that contain the word or item. Similar to the relative frequency, it is used to compare document frequencies between corpora of different sizes.

see also


frequency per million


Statistics used in Sketch Engine