# Rattle: Data Mining by Example # # Copyright (c) 2011 Graham.Williams@togaware.com source("datasets.R") MODEL <- new.env(parent=weatherDS) evalq({ set.seed(42) build.time <- system.time(model <- kmeans(data[-na.obs, numerics], 10)) # The 'fpc' package provides the 'plotcluster' function. require(fpc) # Generate a discriminant coordinates plot. plotcluster(data[-na.obs, numerics], model$cluster) title(main="Discriminant Coordinates kmeans weather", sub=paste("Rattle", format(Sys.time(), "%Y-%b-%d %H:%M:%S"), Sys.info()["user"])) }, MODEL) MODEL$model MODEL$build.time