marginal_multigraph_entropy#
- graph_tool.inference.marginal_multigraph_entropy(g, ecount)[source]#
Compute the entropy of the marginal latent multigraph distribution.
- Parameters:
- g
Graph
Marginal multigraph.
- ecount
EdgePropertyMap
Vector-valued edge property map containing the counts of edge multiplicities.
- g
- Returns:
- eh
EdgePropertyMap
Marginal entropy of edge multiplicities.
- eh
Notes
The mean posterior marginal multiplicity distribution of a multi-edge \((i,j)\) is defined as
\[\pi_{ij}(w) = \sum_{\boldsymbol G}\delta_{w,G_{ij}}P(\boldsymbol G|\boldsymbol D)\]where \(P(\boldsymbol G|\boldsymbol D)\) is the posterior probability of a multigraph \(\boldsymbol G\) given the data.
The corresponding entropy is therefore given (in nats) by
\[\mathcal{S}_{ij} = -\sum_w\pi_{ij}(w)\ln \pi_{ij}(w).\]