unihist(1)

πŸ’– unihist β€” the manual page, but make it cute πŸ’–

okay bestie, so this is unihist, a lil command from the General Commands Manual section (that's section 1, the one for actual runnable commands, iykyk) ✨


πŸŽ€ NAME πŸŽ€

unihist β€” generates a histogram of the characters in a Unicode file. yes it counts your glyphs. it's giving census but for Unicode. πŸ‘‘


🌸 SYNOPSIS 🌸

unihist ([option flags])

πŸ¦‹ DESCRIPTION πŸ¦‹

so unihist makes a histogram of the characters in its input, and that input must be encoded in UTF-8 Unicode, no exceptions bestie πŸ’…

by default, for each character it prints:

  • the frequency of the character as a percentage of the total
  • the absolute number of tokens in the input
  • the UTF-32 code in hexadecimal
  • and, if the character is displayable, the glyph itself as UTF-8 Unicode 🫢

the command line flags let you suppress info you don't want. and here's the ✨iconic✨ part: if you suppress the percentages and counts, you can literally generate a list of the unique characters in the input. obsessed with that actually 😭

output comes out ordered by character code. want it sorted by descending order of frequency instead? pipe it into this:

sort -k1 -n -r

and by default unihist handles all of Unicode 🌈 but if you want to reduce memory usage and increase speed, it may be compiled so as to handle only the Basic Multilingual Plane (plane 0) by defining BMPONLY. tiny unihist, big energy 🧚


✨ COMMAND LINE FLAGS ✨

  • -c β€” suppress printing of counts and percentages. quiet luxury, no numbers πŸ’œ
  • -g β€” suppress printing of glyphs. just codes, no pretty pictures πŸ™ˆ
  • -h β€” print usage information. your little help me bestie πŸŽ€
  • -u β€” suppress printing of the Unicode code as text. bye bye hex πŸ”₯
  • -v β€” print version information. who are you, unihist? πŸ’–

πŸ’œ SEE ALSO πŸ’œ

  • uniname (1)

πŸ“š REFERENCES πŸ“š

  • Unicode Standard, version 5.0

🌟 AUTHOR 🌟

Bill Poser billposer@alum.mit.edu


πŸ’… LICENSE πŸ’…

GNU General Public License


lowkey a whole mood that a Unicode histogram tool from May, 2008 is still out here slaying πŸ’€βœ¨ no cap, this page is the General Commands Manual edition, May 2008, and it ate. periodt. πŸ’–πŸŒΈπŸ¦‹