Returns a dataframe with all pairs of blocks at the desired level and the number of edges between them. Unconnected blocks are ommitted for space savings.
get_block_edge_counts(sbm, level = 1)
sbm |
|
---|---|
level | Level of nodes who's blocks will have their block membership run through MCMC proposal-accept routine. |
Dataframe of block pairs (block_a
and block_b
) and the number of edges between them (count
).
Other modeling:
choose_best_collapse_state()
,
collapse_blocks()
,
collapse_run()
,
get_entropy()
,
get_num_blocks()
,
get_state()
,
mcmc_sweep()
# A small simulated network with random block assignment net <- sim_basic_block_network(n_blocks = 3, n_nodes_per_block = 10) %>% initialize_blocks(3) # Get counts of connections from each given block to the others net %>% get_block_edge_counts()#> block_a block_b count #> 1 node-1_0 node-1_0 32 #> 2 node-1_0 node-1_1 24 #> 3 node-1_0 node-1_2 80 #> 4 node-1_1 node-1_1 5 #> 5 node-1_1 node-1_2 27 #> 6 node-1_2 node-1_2 33