clusterpath.l2 {clusterpath} | R Documentation |
Cluster a matrix of data using the L2 penalty and fused group lasso.
clusterpath.l2(x, ...)
x |
Matrix of data to cluster. |
... |
passed to clusterpath.l2.general |
Toby Dylan Hocking
## cluster the iris data path <- clusterpath.l2(iris[,1:4],gamma=1,verbose=1) plot(path,groups=iris$Species) ## compare with l1 path bpts <- clusterpath.l1.id(iris[,1:4]) plot(bpts) bpts4d <- castbreakpoints(bpts) solutions <- rbind(bpts4d,path) ggplot(solutions,aes(Petal.Length,Petal.Width))+ geom_path(aes(group=interaction(row,solver),colour=norm))