@@ -412,8 +412,8 @@ The hierarchical levels themselves are represented by individual
.. testoutput:: celegans
<BlockState object with 13 blocks (13 nonempty), degree-corrected, for graph <Graph object, directed, with 297 vertices and 2359 edges at 0x...>, at 0x...>
<BlockState object with 5 blocks (5 nonempty), for graph <Graph object, directed, with 13 vertices and 109 edges at 0x...>, at 0x...>
<BlockState object with 2 blocks (2 nonempty), for graph <Graph object, directed, with 5 vertices and 24 edges at 0x...>, at 0x...>
<BlockState object with 5 blocks (5 nonempty), for graph <Graph object, directed, with 13 vertices and 105 edges at 0x...>, at 0x...>
<BlockState object with 2 blocks (2 nonempty), for graph <Graph object, directed, with 5 vertices and 21 edges at 0x...>, at 0x...>
<BlockState object with 1 blocks (1 nonempty), for graph <Graph object, directed, with 2 vertices and 4 edges at 0x...>, at 0x...>
This means that we can inspect the hierarchical partition just as before:
...
...
@@ -454,8 +454,8 @@ case of the `C. elegans` network we have
.. testoutput:: model-selection
:options: +NORMALIZE_WHITESPACE
Non-degree-corrected DL: 8568.61212614
Degree-corrected DL: 8246.48662192
Non-degree-corrected DL: 8507.97432099
Degree-corrected DL: 8228.11609772
Since it yields the smallest description length, the degree-corrected
fit should be preferred. The statistical significance of the choice can
...
...
@@ -481,12 +481,12 @@ fits. In our particular case, we have
.. testoutput:: model-selection
:options: +NORMALIZE_WHITESPACE
ln Λ: -322.125504215
ln Λ: -279.858223272
The precise threshold that should be used to decide when to `reject a
hypothesis <https://en.wikipedia.org/wiki/Hypothesis_testing>`_ is
subjective and context-dependent, but the value above implies that the
particular degree-corrected fit is around :math:`e^{322} \sim 10^{140}`
particular degree-corrected fit is around :math:`e^{280} \sim 10^{121}`
times more likely than the non-degree corrected one, and hence it can be
safely concluded that it provides a substantially better fit.
...
...
@@ -508,12 +508,12 @@ example, for the American football network above, we have:
.. testoutput:: model-selection
:options: +NORMALIZE_WHITESPACE
Non-degree-corrected DL: 1757.84382615
Degree-corrected DL: 1787.60777164
ln Λ: -29.7639454931
Non-degree-corrected DL: 1751.86962605
Degree-corrected DL: 1787.64676873
ln Λ: -35.7771426724
Hence, with a posterior odds ratio of :math:`\Lambda \sim e^{-29} \sim
10^{-13}` in favor of the non-degree-corrected model, it seems like the
Hence, with a posterior odds ratio of :math:`\Lambda \sim e^{-36} \sim
10^{-16}` in favor of the non-degree-corrected model, it seems like the
degree-corrected variant is an unnecessarily complex description for
this network.
...
...
@@ -574,8 +574,8 @@ random partition into 20 groups
.. testoutput:: model-averaging
Change in description length: -360.18357903823386
Number of accepted vertex moves: 4743
Change in description length: -355.3963421220926
Number of accepted vertex moves: 4561
.. note::
...
...
@@ -598,8 +598,8 @@ random partition into 20 groups
.. testoutput:: model-averaging
Change in description length: 0.23920882820149814
Number of accepted vertex moves: 4016
Change in description length: 7.3423409719804855
Number of accepted vertex moves: 3939
Although the above is sufficient to implement model averaging, there is a