print_entropy: Prints the entropy of the different actions

View source: R/print_methods.R

print_entropyR Documentation

Prints the entropy of the different actions

Description

The function prints the vector of entropies for each possible action. Depending on printing options, additional information about the probability calculations can be provided.

Usage

print_entropy(entropy, digits = 3, print_all = FALSE)

Arguments

entropy

The entropy measure from calculate_entropy

digits

The number of digits to round to. Default 3.

print_all

If TRUE will print all information on intermediary calculations

Examples

design <- matrix(c(-1, -1, -1, -1,  1,
                   -1,  0,  0, -1,  0,
                   -1,  0, -1,  0,  0,
                    0,  0, -1,  0, -1), nrow = 4, byrow = TRUE)

entropy <- calculate_entropy(design)

print_entropy(entropy)
print_entropy(entropy, digits = 4)
print_entropy(entropy, print_all = TRUE)


obfuscatoR documentation built on Sept. 8, 2023, 5:48 p.m.