how to partition mst of iris dataset to obtain sub graphs in r -
how to partition mst of iris dataset to obtain sub graphs in r -
i'm new r , can give thought of how obtain sub graphs iris dataset mst tree? here have done little code obtaining mst tree iris dataset.. dono how proceed farther obtain sub trees of original mst tree.. here code..
library(cluster) library(igraph) data<-(iris) g<-graph.data.frame(data,directed=false) plot(g,layout=layout.fruchterman.reingold,edge.label=e(g)$weight) mst<-minimum.spanning.tree(g) plot(mst,layout=layout.reingold.tilford,edge.label=e(mst)$weight) r
Comments
Post a Comment