WLJS LogoWLJS Notebook

Entropy

Entropy[list] gives the base E information entropy of the values in list.

Entropy[k, list] gives the base k information entropy.

Examples

Entropy[{a, b, a, c, b, a}]
(* Log[6] - 2/3 Log[3] *)
Entropy[2, {1, 1, 0, 1, 0}]
(* Entropy in bits *)

Please visit the official Wolfram Language Reference for more details.

On this page