Tutorial 10
Q1. Apply the K-means algorithm to the following dataset, S, to find 2 natural groupings (K = 2) using the Euclidean distance criterion. Start with initial values of cluster centres of m1 and m2 accordingly.
−110 4 35 −1 5 S= 3 4 5 −1 0 1 ,m1= 3 ,m2= 1
Plot the results and show a suitable linear discriminant function for the two clusters and give its weight vector (assuming g(x) = wT x = 0)
Copyright By PowCoder代写 加微信 powcoder
4 0 2 −2
Q2. Consider the dataset X = 2 −2 4 0 , use principal component analysis
a. project the data onto 2D plane,
b. project the data onto 1D plane.
c. The dataset consists of samples from two classes. By observation, find the cluster centres based on the transformed 2D and 1D samples. Classify the new
data x = −2 (after removing the mean) using both sets of clusters centres.
Q3. Competitive learning algorithm (without normalisation) is employed to find 3 cluster centres for the dataset S in Q1. The initial cluster centres are chosen as x1/2, x3/2 and x5/2, and η = 0.1. The algorithm is run for 5 iterations and the samples are chosen in the order of x3, x1, x1, x5, x6 where the left most data is chosen first.
a. Find the cluster centres for each iteration.
b. Plot the samples S and cluster centres in a figure. Classify the samples.
0 c. Classify the new data x = −2 .
Q4. Basic leader follower algorithm (without normalisation), with θ = 3 and η = 0.5, is employed to find the cluster centres of the dataset S in Q1. The algorithm is run for 5 iterations and the samples are chosen in the order of x3, x1, x1, x5, x6 where the left most data is chosen first.
a. Find the cluster centres for each iteration. b. Classify the samples in S.
c. Classify the new data x = −2
−1 1 0 4 3 5
Q5. ApplytheFuzzyK-meansalgorithm,withK=2,tothedataset: S= 3 4 5 −1 0 1 .
Set parameter b = 2, terminate when both coordinates of both cluster centres change by less than 0.5 from one iteration to the next, and start with initial membership
1 0.5 0.5 0.5 0.5 0 valuesequalto: μ= 0 0.5 0.5 0.5 0.5 1 .
Q6. Given the following dataset xT1 = [−1, 3], xT2 = [1, 2], xT3 = [0, 1], xT4 = [4, 0], xT5 = [5,4],xT6 = [3,2] perform hierarchical agglomerative clustering until three clusters are formed (c = 3). Use the Euclidean distance as the similarity metric. To deter- mine the distance between clusters use single-link clustering (the minimum distance between samples in the two clusters).
程序代写 CS代考 加微信: powcoder QQ: 1823890830 Email: powcoder@163.com