normalizedMutualInformation {partitionComparison} | R Documentation |
Normalized Mutual Information
Description
Compute the mutual information (MI
) which is normalized either by the
minimum/maximum partition entropy (H
)
\frac{MI(P, Q)}{\varphi(H(P), H(Q))},\ \varphi \in \{\min, \max\}
or the sum
\frac{2 \cdot MI(P, Q)}{H(P) + H(Q)}
Usage
normalizedMutualInformation(p, q, type = c("min", "max", "sum"))
## S4 method for signature 'Partition,Partition,character'
normalizedMutualInformation(p, q, type = c("min", "max", "sum"))
## S4 method for signature 'Partition,Partition,missing'
normalizedMutualInformation(p, q, type = NULL)
Arguments
p |
The partition |
q |
The partition |
type |
One of "min" (default), "max" or "sum" |
Methods (by class)
-
normalizedMutualInformation(p = Partition, q = Partition, type = character)
: Compute given two partitions -
normalizedMutualInformation(p = Partition, q = Partition, type = missing)
: Compute given two partitions withtype="min"
Author(s)
Fabian Ball fabian.ball@kit.edu
References
Kvalseth TO (1987). “Entropy and Correlation: Some Comments.” IEEE Transactions on Systems, Man and Cybernetics, 17(3), 517–519. ISSN 0018-9472, doi:10.1109/TSMC.1987.4309069.
See Also
Examples
isTRUE(all.equal(normalizedMutualInformation(
new("Partition", c(0, 0, 0, 1, 1)),
new("Partition", c(0, 0, 1, 1, 1)), "min"),
normalizedMutualInformation(
new("Partition", c(0, 0, 0, 1, 1)),
new("Partition", c(0, 0, 1, 1, 1)), "max")
))
[Package partitionComparison version 0.2.6 Index]