Skip to content

zipf

zipf(s, n): number

Defined in: src/global/distributions.ts:367

A rank in 1..n, following the power law behind word frequency.

number

number

number

zipf(1.2, 1000); // 3