View source: R/mod_cluster_utils.R
| e_mapa_3D | R Documentation | 
PCA plot of individuals colored by clusters
e_mapa_3D(pca.model, clusters, colores = NULL, ejes = c(1, 2, 3), etq = F)
pca.model | 
 an object of class PCA [FactoMineR].  | 
clusters | 
 a vector specifying the cluster of each individual.  | 
colores | 
 a vector of color for each cluster.  | 
ejes | 
 a numeric vector of length 3 specifying the dimensions to be plotted.  | 
etq | 
 a boolean, whether to add label to graph or not.  | 
echarts4r plot
Diego Jimenez <diego.jimenez@promidat.com>
p <- FactoMineR::PCA(iris[, -5], graph = FALSE)
clusters <- factor(kmeans(iris[, -5], 3)$cluster)
e_mapa_3D(p, clusters, c("steelblue", "pink", "forestgreen"), etq = FALSE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.