if (FALSE) {
data(PAM)
mid <- lets.midpoint(PAM, method = "PC")
mid2 <- lets.midpoint(PAM, method = "GM")
mid3 <- lets.midpoint(PAM, method = "CMD")
mid4 <- lets.midpoint(PAM, method = "MCC")
mid5 <- lets.midpoint(PAM, method = "PC", planar = TRUE)
mid6 <- lets.midpoint(PAM, method = "GM", planar = TRUE)
mid7 <- lets.midpoint(PAM, method = "CMD", planar = TRUE)
mid8 <- lets.midpoint(PAM, method = "MCC", planar = TRUE)
for (sp in seq_len(nrow(mid))) {
#sp = 4 # Or choose a line or species
plot(PAM, name = mid[sp, 1])
points(mid[sp, -1], col = adjustcolor("blue", .8), pch = 20, cex = 1.5)
points(mid2[sp, -1], col = adjustcolor("green", .8), pch = 20, cex = 1.5)
points(mid3[sp, -1], col = adjustcolor("yellow", .8), pch = 20, cex = 1.5)
points(mid4[sp, -1], col = adjustcolor("purple", .8), pch = 20, cex = 1.5)
points(mid5[sp, -1], col = adjustcolor("orange", .8), pch = 20, cex = 1.5)
points(mid6[sp, -1], col = adjustcolor("black", .8), pch = 20, cex = 1.5)
points(mid7[sp, -1], col = adjustcolor("gray", .8), pch = 20, cex = 1.5)
points(mid8[sp, -1], col = adjustcolor("brown", .8), pch = 20, cex = 1.5)
Sys.sleep(1)
}
}
Run the code above in your browser using DataLab