
Last chance! 50% off unlimited learning
Sale ends in
library(stats)
n <- 20
X <- matrix(runif(n * 10), n, 10)
d <- dist(X)
PC <- prcomp(X)
M <- mst(d)
opar <- par()
par(mfcol = c(2, 2))
plot(M)
plot(M, graph = "nsca")
plot(M, x1 = PC$x[, 1], x2 = PC$x[, 2])
par(opar)
Run the code above in your browser using DataLab