simnetwork | R Documentation |
simnetwork
generates adjacency matrices based on specified probabilities.
simnetwork(dnetwork, normalise = FALSE)
dnetwork |
A list of sub-network matrices, where the (i, j)-th position of the m-th matrix represents the probability that individual |
normalise |
A boolean indicating whether the returned matrices should be row-normalized ( |
A list of (row-normalized) adjacency matrices.
# Generate a list of adjacency matrices
## Sub-network sizes
N <- c(250, 370, 120)
## Probability distributions
dnetwork <- lapply(N, function(x) matrix(runif(x^2), x))
## Generate networks
G <- simnetwork(dnetwork)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.