Description Usage Arguments Value Examples
Compute the base-b
conditional mutual information given joint
p_xyz
and marginal p_xz
, p_yz
, p_z
distributions.
1 | shannon_cond_mutual_info(p_xyz, p_xz, p_yz, p_z, b = 2)
|
p_xyz |
Dist specifying the joint distribution. |
p_xz |
Dist specifying the |
p_yz |
Dist specifying the |
p_z |
Dist specifying the |
b |
Numeric giving the base of the logarithm. |
Numeric giving the Shannon conditional mutual information.
1 2 3 4 5 6 | xyz <- Dist(c(24, 24, 9, 6, 25, 15, 10, 5))
xz <- Dist(c(15, 9, 5, 10))
yz <- Dist(c(9, 15, 10, 15))
z <- Dist(c(3, 5))
shannon_cond_mutual_info(xyz, xz, yz, z) # 0.1259494
shannon_cond_mutual_info(xyz, xz, yz, z, b = 3) # 0.0794652
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.