if (FALSE) {
devAskNewPage(ask = TRUE)
data(iris)
# Show level attributes.
levels(iris[["Class"]])
# Split dataset into train (75
set.seed(5)
Iris <- split(p = 0.6, Dataset = iris, class = 5)
# Estimate number of components, component weights and component
# parameters for train subsets.
n <- range(a.ntrain(Iris))
irisest <- REBMIX(model = "REBMVNORM",
Dataset = a.train(Iris),
Preprocessing = "histogram",
cmax = 10,
Criterion = "ICL-BIC",
EMcontrol = new("EM.Control", strategy = "single"))
plot(irisest, pos = 1, nrow = 3, ncol = 2, what = c("pdf"))
plot(irisest, pos = 2, nrow = 3, ncol = 2, what = c("pdf"))
plot(irisest, pos = 3, nrow = 3, ncol = 2, what = c("pdf"))
# Selected chunks.
iriscla <- RCLSMIX(model = "RCLSMVNORM",
x = list(irisest),
Dataset = a.test(Iris),
Zt = a.Zt(Iris))
iriscla
summary(iriscla)
# Plot selected chunks.
plot(iriscla, nrow = 3, ncol = 2)
}
Run the code above in your browser using DataLab