zilgm_sim | R Documentation |
Generate data from zero-inflated multivariate Poisson or negative binomial distribution under given graph structure.
zilgm_sim(A, n, p, zlvs, family = c("poisson", "negbin"),
signal, theta = NULL, noise)
A |
A p x p adjacency matrix following graph structure. |
n |
The number of observation to generate simulated data. |
p |
The number of variables or nodes to generate simulated data. |
zlvs |
The probability of structural zero for each variable or nodes. |
family |
The distribution to draw samples. |
signal |
The location parameter for distribution. |
theta |
The dispersion parameter for negative binomial distribution. |
noise |
The location parameter for noise distribution. |
A list of two elements:
A |
p x p adjacency matrix of the random graph. |
X |
n x p simulated data. |
Beomjin, Park.
Choi, H., J. Gim, S. Won, Y. J. Kim, S. Kwon, and C. Park, 2017: Network analysis for count data with excess zeros. BMC genetics, 18, no. 1, 1-10.
Park, B., H. Choi, C. Park, 2021: Negative binomial graphical model with excess zeros.
zilgm
require(ZILGM)
set.seed(1)
n = 100; p = 10; prob = 2 / p;
A = generate_network(p, prob, type = "random")
simul_dat = zilgm_sim(A = A, n = n, p = p, zlvs = 0.1,
family = "negbin", signal = 1.5, theta = 0.5, noise = 0.0)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.