mlvsbm_create_network {MLVSBM} | R Documentation |
Create a MLVSBM object from observed data
Description
Create a MLVSBM object from observed data
Usage
mlvsbm_create_network(
X,
A,
directed = NULL,
distribution = list("bernoulli", "bernoulli")
)
Arguments
X |
A list of 2 squares binary matrices, the first one being the individual or lower level the second one being the organizational or upper level |
A |
A matrix the affiliation matrix with individuals in rows and organizations in columns |
directed |
A list of 2 boolean are the upper and lower level directed or not. Default will check if the matrix are symmetric or not. |
distribution |
A list for the distribution of X, only "bernoulli" is implemented |
Value
An unfitted MLVSBM object corresponding to the multilevel network
Examples
ind_adj <- matrix(stats::rbinom(n = 10**2, size = 1, prob = .2),
nrow = 10, ncol = 10)
org_adj <- matrix(stats::rbinom(n = 10**2, size = 1, prob = .3),
nrow = 10, ncol = 10)
affiliation <- diag(1, 10)
my_mlvsbm <- mlvsbm_create_network(X = list(I = ind_adj, O = org_adj),
directed = list(I = FALSE, O = FALSE),
A = affiliation)
[Package MLVSBM version 0.2.4 Index]