Learn R Programming

DeducerExtras (version 1.7)

predict.kmeans: Applies cluster labels

Description

Applies cluster labels

Usage

"predict"(object,data=NULL,...) applyModel(object,data,...)

Arguments

object
A kmeans object
data
a dataset to apply the model to
...
Additional parameters

Value

predict returns a vector of cluster assignments. applyModel returns the data with a column of cluster assignments appended to it.