Skip to contents

Calculate entropy delta of the SBM before and after the proposed move and the ratio of the probabilities of moving to the proposed block before the move and moving back to the original block after the move.

Usage

get_proposal_results(
  curr_v,
  proposed_new_block,
  old_entropy,
  G,
  old_partition,
  block.edges,
  eps = 0.1,
  beta = 1,
  dc = FALSE
)

Arguments

curr_v

A node in graph.

proposed_new_block

An integer giving the proposed block id.

old_entropy

A number giving the pre move entropy

G

An igraph graph.

old_partition

Vector of integer values giving the block membership of each vertex pre move.

block.edges

a list of all incident edge ids per block

eps

(optional) A number controlling the randomness of moves.

beta

(optional) A number controlling the greediness of moves.

dc

Whether to use degree correction.

Value

A new group membership for vertex.