This function builds a object "Network" by simulating a matrix of valued adjacencies from a number of vertices, a proportion of edges and the range of the uniform distribution that is used to build the adjacency matrix. An optional vector of labels may be given.
- number of genes
- edges proportion in the network
- vector with 4 elements specifying range values for the adjacency matrix generation (minimum negative value, maximum negative value, minimum positive value, maximum positive value)
- an optional vector of labels for the edges
a list that contains out$Vertices$Num the number of vertices, out$Vertices$Labels a vector of labels of the vertices, out$Vertices$Regulated a vector of the regulated vertices, out$Edges$Prop the proportion of edges, out$Edges$Num the number of edges, out$AdjMatrix an adjacency matrix (binary) and out$A a valued adjacency matrix.
library(G1DBN) ## number of genes p <- 10 ## the network - adjacency Matrix MyNet <- SimulNetworkAdjMatrix(p,0.05,c(-1,0,0,1)) MyNet ## initializing the B vector B <- runif(p,0,0.5) ## initializing the variance of the noise sigmaEps <- runif(p,0.1,0.8) ## initializing the process Xt X0 <- B + rnorm(p,0,sigmaEps*10) ## number of time points n <- 20 ## the AR(1) times series process Xn <- SimulGeneExpressionAR1(MyNet$AdjMatrix,B,X0,sigmaEps,n)
Documentation reproduced from package G1DBN, version 3.1. License: GPL (>= 2)