### extend Rock example
data(Votes)
x <- as.dummy(Votes[-17])
rc <- rockAll(x, n=2, m=100, theta=0.73, predict=FALSE, debug=TRUE)
gc <- gknn(dists(x, rc$y, method="binary"), rc$cl, k=3)
table(gc[rc$s], rc$cl)
Run the code above in your browser using DataLab