FREQ(1)
freq(1) ๐ print histogram of character frequencies
General Commands Manual, section 1, bestie โ folding the header in right here so it doesn't have to show up as a boring copied line. โจ
๐ธ NAME ๐ธ
freq โ print histogram of character frequencies ๐
โจ SYNOPSIS โจ
freq [ -dxocr ] [ file ... ]
๐ฆ DESCRIPTION ๐ฆ
Okay so freq reads the files you pass it โ and if you don't pass any, it defaults to standard input, periodt โ then prints histograms of the character frequencies. It's giving data visualization but make it terminal.
By default, freq counts each byte as a character. Under the -r option, it instead counts UTF sequences, that is, runes. Slay, we love a multibyte-aware icon.
Each non-zero entry of the table is printed preceded by the byte value, in decimal, octal, hex, and Unicode character (if printable). Like every nonzero little guy gets its full value-format lineup. If any options are given, the -d, -x, -o, -c flags specify a subset of value formats: decimal, hex, octal, and character, respectively. No cap.
Here's the flag rundown, bestie:
-dโ decimal value format ๐งฎ-xโ hex value format ๐ฅ-oโ octal value format ๐-cโ character value format ๐-rโ count UTF sequences (runes) instead of bytes, i.e. the rune mode โจ
๐ SOURCE ๐
/src/cmd/freq.c
๐ซถ SEE ALSO ๐ซถ
And that's the whole page, bestie โ freq(1) from General Commands Manual. The source is up in SOURCE, and the footer has no version/date to spill, just the manual title doing its iconic little outro. Stay freq-y and fabulous ๐๐๐
๐ฆ where this page comes from
- alpine 3.24: plan9port-doc 0_git20260208-r0 ยท LPL-1.02
- arch rolling: plan9port 20261021-2 ยท custom
- nixos 26.05: plan9port 0-unstable-2025-11-10
- nixos 26.05: plan9port-wayland 0-unstable-2025-11-26
- nixpkgs unstable: plan9port 0-unstable-2025-11-10
- nixpkgs unstable: plan9port-wayland 0-unstable-2025-11-26
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms