entropy: Calculate the entropy

View source: R/utils.R

entropyR Documentation

Calculate the entropy

Description

Calculate the Shannon's entropy.

Usage

entropy(x)

Arguments

x

a numeric vector.

Value

numeric. entropy

Examples

set.seed(123)
x <- sample(1:10, 20, replace = TRUE)

entropy(x)


choonghyunryu/dlookr documentation built on June 11, 2024, 9:12 a.m.