powered by
Perform the folding test of unimodality
folding.test(X)
$nxd$ matrix (n observations, d dimensions)
1 if unimodal, 0 if multimodal
# NOT RUN { library(MASS) n = 10000 d = 3 mu = c(0,0,0) Sigma = matrix(c(1,0.5,0.5,0.5,1,0.5,0.5,0.5,1), ncol = d) X = mvrnorm(n = n, mu = mu, Sigma = Sigma) m = folding.test(X) # }
Run the code above in your browser using DataLab