simulateBlockDiagNetwork: Simulate a modular network
Description
This function simulates a modular network with p variables based on the partition of variables into blocks labels.
Usage
simulateBlockDiagNetwork(p, labels)
Arguments
p
number of variables in the network
labels
vector indicating the partition of variables into blocks
Value
Asimulated adjacency matrix
Csimulated correlation matrix
Pcorsimulated partial correlation matrix
labelsvector indicating the partition of variables into blocks provided as input of the function
Details
To simulate covariance matrices, we use the methodology detailed in Giraud, S. Huet, and N. Verzelen. Graph selection with GGMselect. 2009
http://fr.arxiv.org/abs/0907.0619https://cran.r-project.org/package=GGMselect
## number of variablesp <- 100
## number of blocksK <- 15
## vector of partition into blockslabels <- factor(rep(1:K, length.out=p))
## simulate network g <- simulateBlockDiagNetwork(p,labels)