Skip to contents

Creates an graphon representing a Stochastic Block Model (SBM).

Usage

sbm_graphon(mat, n)

Arguments

mat

The matrix representing the SBM

n

The dimension of the matrix

Value

An nxn matrix

Examples

# example code
mat <- matrix(c(0.9, 0.01, 0.02,
0.01, 0.8, 0.03,
0.02, 0.03, 0.7), nrow = 3, byrow = TRUE)
W <- sbm_graphon(mat, 100)
plot_graphon(W)