h2o.entropy: Shannon entropy

View source: R/frame.R

h2o.entropyR Documentation

Shannon entropy

Description

Return the Shannon entropy of a string column. If the string is empty, the entropy is 0.

Usage

h2o.entropy(x)

Arguments

x

The column on which to calculate the entropy.

Examples

## Not run: 
library(h2o)
h2o.init()
buys <- as.h2o(c("no", "no", "yes", "yes", "yes", "no", "yes", "no", "yes", "yes","no"))
buys_entropy <- h2o.entropy(buys)

## End(Not run)

h2o documentation built on May 29, 2024, 4:26 a.m.