gen.edge.list | R Documentation |
Generate edge list from a distance matrix Duplicates are not deleted, because they will not be counted by Kruskal's algorithm If a check is O(1), this only adds an O(E) overhead, which is negligible
gen.edge.list(mat)
mat |
The distance matrix. |
A data frame with three columns: 'from', 'to', 'dist'.