# NOT RUN {
set.seed(11)
A <- matrix(rnorm(10*200), nrow = 200) ## No change-point
M1 <- detect.ic(A, approach = 'euclidean', scales = -1)
M2 <- detect.ic(A, approach = 'infinity', scales = -1)
M1$changepoints
M2$changepoints
set.seed(1)
num.nodes <- 30 # number of nodes
etaA.1 <- 0.95
etaA.2 <- 0.05
pcor1 <- GeneNet::ggm.simulate.pcor(num.nodes, etaA = etaA.1)
pcor2 <- GeneNet::ggm.simulate.pcor(num.nodes, etaA = etaA.2)
n <- 50
data1 <- GeneNet::ggm.simulate.data(n, pcor1)
data2 <- GeneNet::ggm.simulate.data(n, pcor2)
X1 <- rbind(data1, data2, data1, data2) ## change-points at 50, 100, 150
N1 <- detect.ic(X1, approach = 'euclidean', scales = -1)
N2 <- detect.ic(X1, approach = 'infinity', scales = -1)
N1$changepoints
N2$changepoints
N1$no.of.cpts
N2$no.of.cpts
N1$sol_path
N2$sol_path
# }
Run the code above in your browser using DataLab