entropy#
- infomeasure.entropy(data, approach: str, *args, **kwargs: any)[source]#
Calculate the entropy using a functional interface of different estimators.
Supports the following approaches:
discrete:Discrete entropy estimator.kernel:Kernel entropy estimator.[
metric,kl]:Kozachenko-Leonenko entropy estimator.renyi:Renyi entropy estimator.[
ordinal,symbolic,permutation]:Ordinal / Permutation entropy estimator.tsallis:Tsallis entropy estimator.
- Parameters:
- dataarray_like
The data used to estimate the entropy.
- approach
str The name of the estimator to use.
- *args: tuple
Additional arguments to pass to the estimator.
- **kwargs: dict
Additional keyword arguments to pass to the estimator.
- Returns:
floatThe calculated entropy.
- Raises:
ValueErrorIf the estimator is not recognized.