R/entropy.R

Defines functions entropy

# calculation of the entropy
entropy <- function(x)
{
-sum(x*log(x, base=length(x)))
} 

Try the lcda package in your browser

Any scripts or data that you put into this service are public.

lcda documentation built on March 18, 2022, 5:24 p.m.