This function compares the robustness of two community detection algorithms.
robinCompare(
graph,
method1 = c("walktrap", "edgeBetweenness", "fastGreedy", "leadingEigen", "louvain",
"spinglass", "labelProp", "infomap", "optimal", "other"),
method2 = c("walktrap", "edgeBetweenness", "fastGreedy", "leadingEigen", "louvain",
"spinglass", "labelProp", "infomap", "optimal", "other"),
FUN1 = NULL,
FUN2 = NULL,
measure = c("vi", "nmi", "split.join", "adjusted.rand"),
type = c("independent", "dependent"),
directed = FALSE,
weights = NULL,
steps = 4,
spins = 25,
e.weights = NULL,
v.weights = NULL,
nb.trials = 10,
verbose = TRUE
)
A list object with two matrices: - the matrix "Mean1" with the means of the procedure for the first method - the matrix "Mean2" with the means of the procedure for the second method
The output of prepGraph.
The first clustering method, one of "walktrap", "edgeBetweenness", "fastGreedy", "louvain", "spinglass", "leadingEigen", "labelProp", "infomap","optimal".
The second custering method one of "walktrap", "edgeBetweenness","fastGreedy", "louvain", "spinglass", "leadingEigen", "labelProp", "infomap","optimal".
personal designed function when method1 is "others".
see methodCommunity
.
personal designed function when method2 is "others".
see methodCommunity
.
The stability measure, one of "vi", "nmi", "split.join", "adjusted.rand" all normalized and used as distances. "nmi" refers to 1- nmi and "adjusted.ran" refers to 1-adjusted.rand.
The type of robin construction, dependent or independent.
This argument is settable only for "edgeBetweenness" method.
This argument is not settable for "infomap" method.
This argument is settable only for "leadingEigen"and"walktrap" method.
This argument is settable only for "infomap" method.
This argument is settable only for "infomap" method.
This argument is settable only for "infomap" method.
This argument is settable only for "infomap" method.
flag for verbose output (default as TRUE).
my_file <- system.file("example/football.gml", package="robin")
graph <- prepGraph(file=my_file, file.format="gml")
robinCompare(graph=graph, method1="louvain",
method2="fastGreedy", measure="vi", type="independent")
Run the code above in your browser using DataLab