# NOT RUN {
set.seed(1234567)
res = generate_data(n1 = 50, n2 = 60, p1 = 5, p2 = 50)
es = res$es
print(es)
covCtrl = res$covCtrl
covCase = res$covCase
# we expect cov for 1st 5 genes are different between cases and controls
print(round(covCtrl[1:5, 1:5], 2))
print(round(covCase[1:5, 1:5], 2))
# we expect cov for other genes are same between cases and controls
print(round(covCtrl[6:10, 6:10], 2))
print(round(covCase[6:10, 6:10], 2))
res2 = construct_network(es = es,
cor_method = "st5",
pseudo_adjust_cutoff = FALSE,
var.grp = "grp",
pAdjMethod = 'fdr',
cutoff = 0.05,
nPseudo = 25)
print(res2$graph)
print(res2$network_dat)
# }
Run the code above in your browser using DataLab