Contenido del Curso
Cluster Analysis
Cluster Analysis
1. Clustering Fundamentals
Challenge: Implementing K-Means Clustering
Tarea
Swipe to start coding
You are given a synthetic dataset stored in the data
variable.
- Initialize a K-means model with
3
clusters, setrandom_state
to42
,n_init
to'auto'
and store it in thekmeans
variable. - Fit the model on the dataset, predict the cluster labels, and store the result in the
labels
variable. - For each cluster
i
, extract the points belonging to this cluster and store the result in thecluster_points
variable.
Solución
¿Todo estuvo claro?
¡Gracias por tus comentarios!
Sección 3. Capítulo 7
Challenge: Implementing K-Means Clustering
Tarea
Swipe to start coding
You are given a synthetic dataset stored in the data
variable.
- Initialize a K-means model with
3
clusters, setrandom_state
to42
,n_init
to'auto'
and store it in thekmeans
variable. - Fit the model on the dataset, predict the cluster labels, and store the result in the
labels
variable. - For each cluster
i
, extract the points belonging to this cluster and store the result in thecluster_points
variable.
Solución
¿Todo estuvo claro?
¡Gracias por tus comentarios!
Sección 3. Capítulo 7