predict.GaussianMixture {hana.ml.r} | R Documentation |
Similar to other predict methods, this function predicts fitted values from a fitted GaussianMixture object.
## S3 method for class 'GaussianMixture' predict(model, data, key, features = NULL, ...)
model |
|
data |
|
key |
|
features |
|
Predicted values are returned as a DataFrame, structured as follows.
ID column, with same name and type as data 's ID column.
Cluster_ID, type INTEGER, the assigned cluster ID.
PROBABILITY, type DOUBLE, Probability that the instance belong to a particular cluster.
## Not run: #'Perform the predict on DataFrame data2 using "GaussianMixture" objectc gmm: > data2$Collect() ID X1 X2 X3 0 0.10 0.10 1 1 0.11 0.10 1 2 0.10 0.11 1 3 0.11 0.11 1 4 0.12 0.11 1 > fitted <- predict(model = gmm, data = data2) > fitted$Collect() ID CLUSTER_ID PROBABILITY 0 0 1 1 0 1 2 0 0 3 0 0 4 0 0 0 1 0 1 1 0 2 1 1 3 1 1 4 1 1 ## End(Not run)