# Import data (data are imported from internet) decathlon <- read.table("https://husson.github.io/livre_StatR/decathlon.csv", header=TRUE, sep=";",dec=".", row.names=1, check.names=FALSE) summary(decathlon) # Loading FactoMineR library(FactoMineR) # PCA res <- PCA(decathlon, quanti.sup=11:12, quali.sup=13, ncp=Inf) res$eig res <- PCA(decathlon, quanti.sup=11:12, quali.sup=13, ncp=8) # Hierarchical ascendant clustering res.hcpc <- HCPC(res, kk=Inf, min=3, max=10, consol=TRUE) # Hierarchical tree on the PCA dimensions 3 and 4 plot(res.hcpc, axes=3:4) # Outputs names(res.hcpc) res.hcpc$call$t res.hcpc$data.clust res.hcpc$desc.var res.hcpc$desc.axes plot(res.hcpc,axes=c(1,3)) res.hcpc$desc.ind