Question: K - means. You are given three data samples: i 1 2 3 xi 1 - 1 1 4 xi 2 0 0 4 (
Kmeans. You are given three data samples:
i
xi
xi
a points We want to have K cluster. After Kmean finishes on the above training
data, what are the centers of the two clusters? What is the equation for the boundary of
the two clusters?
b points Suppose you want to use clustering for outlier detection. You find cluster
means ii K on the training data. Then, given a new data xand a threshold
t you declare xan outlier if kxik tfor all i Complete the following function
to implement the outlier detection on a matrix of data X The output is outi if the
sample Xi: is an outlier, and outi otherwise. You must specify the other inputs of
your function. Avoid for loops for full credit.
def outlier detectX:
return out
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
