Skip to main content

What Is Cluster Analysis? Hierarchical and K-Means Clustering

Daniel HaDaniel Ha · Seoul National University PhD Student
Last updated: 2026-08-25·3 min read
Cluster analysis is an exploratory method that groups cases with similar characteristics into a few homogeneous clusters, divided mainly into hierarchical and k-means clustering. It proceeds by standardizing variables, computing distances, forming clusters, and deciding the number of clusters.

What Is Cluster Analysis?

Cluster analysis divides data into natural groups based on similarity between cases, without any predetermined group membership. It runs in the opposite direction from discriminant analysis, where the groups already exist and membership is predicted.

When Do You Use Cluster Analysis?

Use it to segment customers or respondents into types, or to sort observations into a few profiles whose characteristics you then compare. Keep in mind that the resulting groups are derived from the data, not from theory.

What Types of Cluster Analysis Are There?

They differ in how clusters are formed.

TypeCharacteristics
Hierarchical clusteringMerge process visible in a dendrogram, suits small samples
K-means clusteringNumber of clusters specified in advance, suits large samples
Two-step clusteringSuits large data and mixed variable types

How Do You Run a Cluster Analysis?

Work in order from standardizing variables to interpretation.

Step 1: Standardize the Variables

Standardize variables (z-scores) so that distance computations are not dominated by measurement scale.

Step 2: Compute Distances and Form Clusters

Compute similarity between cases with Euclidean distance or a comparable measure, then form clusters using your chosen method.

Step 3: Decide the Number of Clusters

Determine an appropriate number using the dendrogram, the elbow method, or similar criteria.

Step 4: Profile the Clusters

Compare the average characteristics of each cluster, then name and interpret them.

How Do You Decide the Number of Clusters?

In hierarchical clustering, look for the point where merge distance increases sharply, and in k-means consult the elbow method or the silhouette coefficient. Decide by weighing statistical criteria together with interpretability.

Summary

Cluster analysis groups cases into homogeneous clusters through standardization, distance computation and clustering, deciding the number of clusters, and profiling. Standardize variables first, and choose the number of clusters on both statistical and interpretive grounds. It differs from discriminant analysis, which predicts membership in known groups, and from factor analysis, which reduces item structure.