Commit 9466363f authored by Tiago Peixoto's avatar Tiago Peixoto

Fix docstrings

parent f1ac6991
Pipeline #221 failed with stage
......@@ -676,9 +676,9 @@ will output:
niter: 53 count: 9 breaks: 1 min_S: 702.85027 max_S: 761.09434 S: 735.06773 ΔS: 24.1310 moves: 28
niter: 54 count: 10 breaks: 2 min_S: 702.85027 max_S: 761.09434 S: 738.16756 ΔS: 3.09983 moves: 115
Note that the value of `wait` above was made purposefully low so that
Note that the value of ``wait`` above was made purposefully low so that
the output would not be overly long. The most appropriate value requires
experimentation, but a typically good value is `wait=1000`.
experimentation, but a typically good value is ``wait=1000``.
The function :func:`~graph_tool.inference.mcmc_equilibrate` accepts a
``callback`` argument that takes an optional function to be invoked
......@@ -767,7 +767,7 @@ analogous, but now we make use of
When using :class:`~graph_tool.inference.NestedBlockState` instances
to perform model averaging, they need to be constructed with the
option `sampling=True`.
option ``sampling=True``.
Here we perform the sampling of hierarchical partitions using the same
network as above.
......
......@@ -1658,7 +1658,7 @@ class BlockState(object):
... ds, nmoves = state.mcmc_sweep(niter=10)
... pe = state.collect_edge_marginals(pe)
>>> gt.bethe_entropy(g, pe)[0]
6.65429696440...
-59.2541131...
"""
if p is None:
......@@ -1712,7 +1712,7 @@ class BlockState(object):
... ds, nmoves = state.mcmc_sweep(niter=10)
... pv = state.collect_vertex_marginals(pv)
>>> gt.mf_entropy(g, pv)
29.84318996...
25.98257...
>>> gt.graph_draw(g, pos=g.vp["pos"], vertex_shape="pie",
... vertex_pie_fractions=pv, output="polbooks_blocks_soft_B4.pdf")
<...>
......@@ -1778,7 +1778,7 @@ class BlockState(object):
... ds, nmoves = state.mcmc_sweep(niter=10)
... ph = state.collect_partition_histogram(ph)
>>> gt.microstate_entropy(ph)
124.092176...
128.055896...
"""
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment