Skip to contents

The vector is renormalised on entry, so a pmf that sums to 0.999 through rounding does not silently shift the entropy and a caller who passes counts gets the answer they meant.

Usage

Tsalls(p, q)

Arguments

p

Non-negative weights, renormalised to sum to one.

q

Entropic index; q = 1 gives Shannon entropy in nats.

Value

List with estimate, k, q.

Details

Formula: S_q = (1 - sum_i p_i^q) / (q - 1).

References

Tsallis, C. (1988). J Stat Phys 52:479-487, equation (1).

Examples

Tsalls(p = 0.5, q = 0.5)
#> $estimate
#> [1] 0
#> 
#> $k
#> [1] 1
#> 
#> $q
#> [1] 0.5
#> 
#> $method
#> [1] "Tsallis q-entropy of a supplied pmf"
#> 
#> attr(,"class")
#> [1] "morie_rich_result" "list"