Home Knowledge Base Clustering

Clustering is an unsupervised machine learning technique that groups data points into clusters where items within a cluster are more similar to each other than to items in other clusters — requiring no labeled training data, making it essential for exploratory data analysis, customer segmentation, document grouping, anomaly detection, and any scenario where you need to discover natural structure in data without predefined categories.

What Is Clustering?

Major Clustering Algorithms

AlgorithmApproachRequires K?Cluster ShapeScalability
K-MeansCentroid-basedYes (pick K upfront)Spherical/convexExcellent (millions of points)
DBSCANDensity-basedNo (discovers K)Arbitrary shapesGood (with spatial index)
HierarchicalTree-based (dendrogram)No (cut at any level)AnyPoor (O(N²) memory)
HDBSCANDensity-based (improved DBSCAN)NoArbitrary + variable densityGood
Gaussian MixtureProbabilisticYesEllipticalModerate

K-Means (Most Common)

StepProcess
1. InitializeRandomly place K centroids
2. AssignEach point → nearest centroid
3. UpdateRecalculate centroid as mean of assigned points
4. RepeatUntil centroids stop moving (convergence)

DBSCAN (Density-Based)

Use Cases

DomainTaskAlgorithm
MarketingCustomer segmentation (RFM analysis)K-Means
NLPTopic discovery in document collectionsK-Means on embeddings
SecurityNetwork intrusion detection (anomalous traffic)DBSCAN
E-commerceProduct recommendation clustersHierarchical
BiologyGene expression groupingHDBSCAN

Clustering is the fundamental unsupervised learning technique for discovering natural structure in data — enabling businesses to segment customers, researchers to discover groups, and engineers to detect anomalies, all without the expensive labeled datasets required by supervised methods.

clusteringkmeansgroup

Explore 500+ Semiconductor & AI Topics

From EUV lithography to CUDA optimization — search the full knowledge base or chat with our AI assistant.