I am a new at R language. I have two data sets.One is labeled which is the "Training" data set(Iris data set) and the other is the "Test" data set which is an unlabeled data set. I need to cluster the "Iris" data set and then use the centers of the clusters to place each of the test case into a cluster based upon closest distance, and then assign each of the test case to a cluster.
set.seed(20)
pCluster <- kmeans(Trainingdata[, 3:4], 3, nstart = 20)
pCluster
The above code does cluster the "Training" data set but don't know how to use the centers I get from the above code to label the "Test" data set. Any help would be appreciated.