- All Implemented Interfaces:
- WarpScriptAggregatorFunction, WarpScriptBucketizerFunction, WarpScriptMapperFunction, WarpScriptReducerFunction
public class ShannonEntropy
extends NamedWarpScriptFunction
implements WarpScriptMapperFunction, WarpScriptBucketizerFunction, WarpScriptReducerFunction
Compute a Shannon Entropy, considering GTS values to be number of occurrences of the underlying symbol.
The nature of the underlying symbol is not important.
The returned entropy is normalized by log(N) where N is the sum of occurrences.