Hierarchical Clustering — linkage(y)
Hi,
I don’t fully understand the linkage function and its outputs.
>> x=[1 2 6 8]';
>> y=pdist(x)y = 1 5 7 4 6 2>> Z=linkage(y)Z = 1 2 1
3 4 2
5 6 4
For Z, what does the first and second column stand for? What is the third column? How was the third column calculated based on the input data x and y?
NOTE:-
Matlabsolutions.com provide latest MatLab Homework Help,MatLab Assignment Help for students, engineers and researchers in Multiple Branches like ECE, EEE, CSE, Mechanical, Civil with 100% output.Matlab Code for B.E, B.Tech,M.E,M.Tech, Ph.D. Scholars with 100% privacy guaranteed. Get MATLAB projects with source code for your learning and research
Only just figured it out.
The first and second columns are the new group number after clustering.
4 elements in x each was given a group number from 1 to 4.
The system will then group element 1 and 2 in x together and give a new group number ‘5’.
The system will then group element 6 and 8 in x together and give a new group number ‘6’.
The system will at last group ‘5’ and ‘6’ together while group 5 looks like (1,2), and group 6 looks like (6,8).
the third column is the distance between the two group.
first number in column 3 is 1, that is the difference between elements 1 and 2.
SEE COMPLETE ANSWER CLICK THE LINK