pmml.kmeans {pmml} | R Documentation |
Generate the PMML representation for a KMeans object (cluster). The kmeans object (a cluster described by k centroids) is converted into a PMML representation. The PMML can then be imported into other systems that accept PMML.
## S3 method for class 'kmeans': pmml(model, model.name="KMeans_Model", app.name="Rattle/PMML", description="KMeans cluster model", copyright=NULL, transforms=NULL, ...)
model |
a kmeans object. |
model.name |
a name to give to the model in the PMML. |
app.name |
the name of the application that generated the PMML. |
description |
a descriptive text for the header of the PMML. |
copyright |
the copyright notice for the model. |
transforms |
a coded list of transforms performed. |
... |
further arguments passed to or from other methods. |
Package home page: http://rattle.togaware.com
PMML home page: http://www.dmg.org
ds <- rbind(matrix(rnorm(100, sd = 0.3), ncol = 2), matrix(rnorm(100, mean = 1, sd = 0.3), ncol = 2)) colnames(ds) <- c("Dimension1", "Dimension2") cl <- kmeans(ds, 2) pmml(cl)