Cluster Analysis
Cluster Analysis discovers natural subgroups in your data based on similarity, without knowing groups in advance. Useful for patient phenotyping and exploratory pattern discovery.
Step 1 — Provide your data
Observations x variables (numeric). Supports Excel Import, Sample Data Generator, and Manual Entry.
Step 2 — Configure
Method:
| Method | What it does |
|---|---|
| K-Means | Partitions into k clusters minimising within-cluster variance |
| Hierarchical | Builds tree of nested clusters |
Linkage (hierarchical): Ward (default), Single, Complete, Average.
Number of clusters (k): Fixed or guided by elbow/silhouette.
Step 3 — Results
- Cluster assignments and sizes
- Cluster centroids (variable means per cluster)
- Silhouette scores (per-subject and average)
- Elbow method plot (WSS for k=2 to 8)
- Scatter plot (subjects coloured by cluster)
- Dendrogram (hierarchical only)
A UniversalChatBot is available for discussion.
Statistical methods used
Distance: Euclidean d(a,b) = sqrt(sum((a_j - b_j)^2))
K-Means: K-Means++ initialisation, max 100 iterations, minimises WSS.
Hierarchical: Agglomerative with chosen linkage. Ward minimises variance increase.
Silhouette: s(i) = (b(i) - a(i)) / max(a(i), b(i))
| Average silhouette | Label |
|---|---|
| > 0.70 | Strong structure |
| 0.50 - 0.70 | Reasonable |
| 0.25 - 0.50 | Weak |
| <= 0.25 | No substantial structure |
Elbow method: K-Means for k=2..8 (3 restarts each), plot WSS vs k.
No formal hypothesis test — clustering is exploratory and descriptive.