create a blockmod
object
blockmod(fixkappa, logd, dcond, r, ...)
Logical - is kappa fixed or can it vary under the model?
function(blocks)
- log density for blocks
function(blocks, i)
- conditional density for the block assignment i
in blocks
function(n), sorted=FALSE
- samples a blocks object from the model
parameters of the model for use in r
, logd
, dcond
a blockmod
object
A block model is a probability model for a blocks
object.
This class creates a closure with three functions:
- a random method for sampling block a structure from the model with n
nodes; a
- a log-density method for computing the log-density of a given block structure in a blocks
object
- a conditional density function that takes a blocks
object and a node i