Skip to content

Commit d9da7bd

Browse files
authored
Update README.md
1 parent b2c7db7 commit d9da7bd

File tree

1 file changed

+30
-0
lines changed
  • Machine_Learning/src/Hierarchical Clustering

1 file changed

+30
-0
lines changed
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,32 @@
11
# Hierarchical Clustering
22
Used Hierarchical Clustering algortihm to cluster different segments of customers of a mall based on their income and expenditure.
3+
4+
## Understanding Clustering
5+
Clustering is basically a technique that groups similar data points such that the points in the same group are more similar to each other than the points in the other groups. The group of similar data points is called a Cluster.
6+
7+
## Agglomerative Hierarchical clustering Technique
8+
In this technique, initially each data point is considered as an individual cluster. At each iteration, the similar clusters merge with other clusters until one cluster or K clusters are formed.
9+
The basic algorithm of Agglomerative is straight forward.
10+
- Compute the proximity matrix
11+
- Let each data point be a cluster
12+
- Repeat: Merge the two closest clusters and update the proximity matrix
13+
- Until only a single cluster remains
14+
- Key operation is the computation of the proximity of two clusters
15+
16+
### Algorithm
17+
Step- 1: In the initial step, we calculate the proximity of individual points and consider all the data points as individual clusters.
18+
19+
Step- 2: In step two, similar clusters are merged together and formed as a single cluster.
20+
21+
Step- 3: We again calculate the proximity of new clusters and merge the similar clusters to form new clusters.
22+
23+
Step- 4: Calculate the proximity of the new clusters. The similar clusters are merged together to form a new cluster.
24+
25+
Step- 5: Finally, all the clusters are merged together and form a single cluster.
26+
27+
### Dendogram
28+
The Hierarchical clustering Technique can be visualized using a Dendrogram.
29+
A Dendrogram is a tree-like diagram that records the sequences of merges or splits.
30+
31+
Here Hierarchical Clustering Technique has been applied on a sample dataset and the relevant dendogram & clustered data point graph have been included here.
32+
*Hierarchical-Clustering.py* guides the entire hierarchical clustering approach along with data preprocessing and result generation.

0 commit comments

Comments
 (0)