shannon_entropy: Computes Shannon entropy

Description Usage Arguments Examples

View source: R/shannon_entropy.R

Description

This function computes the shannon entropy of a probability distribution.

Usage

1
shannon_entropy(pDist, log_type = "nats")

Arguments

pDist

a probability distribution as a vector or a matrix of probability distributions columns.

log_type

choose nats or bits, defaults to nats.

Examples

1
shannon_entropy(c(.5,.5), log_type='bits')

neilbramley/acl_source documentation built on May 29, 2019, 6:53 p.m.