evaluate_significance_r {clustAnalytics}R Documentation

Evaluates the significance of a graph's clusters

Description

Computes community scoring functions to the communities obtained by applying the given clustering algorithms to a graph. These are compared to the same scores for randomized versions of the graph obtained by a switching algorithm that rewires edges.

Usage

evaluate_significance_r(
  g,
  alg_list = list(Louvain = cluster_louvain, `label prop` = cluster_label_prop, walktrap
    = cluster_walktrap),
  no_clustering_coef = FALSE,
  gt_clustering = NULL,
  table_style = "default",
  ignore_degenerate_cl = TRUE,
  Q = 100,
  lower_bound = 0,
  weight_sel = "const_var",
  n_reps = 5,
  w_max = NULL
)

Arguments

g

Graph to be analyzed (as an igraph object)

alg_list

List of clustering algorithms, which take an igraph graph as input and return an object of the communities class.

no_clustering_coef

Logical. If TRUE, skips the computation of the clustering coefficient, which is the most computationally costly of the scoring functions.

gt_clustering

Vector of integers that correspond to labels of the ground truth clustering. The scoring functions will be evaluated on it.

table_style

By default returns a table with three columns per algorithm: the original one, the mean of the corresponding rewired scores (suffix "_r") and it's percentile rank within the distribution of rewired scores (suffix "_percentile"). If table_style == "string", instead returns a table with a column per algorithm where each element is of the form "original|rewired(percentile)"

ignore_degenerate_cl

Logical. If TRUE, when computing the means of the scoring functions, samples with only one cluster will be ignored. See rewireCpp.

Q

Numeric. Parameter that controls the number of iterations of the switching algorithm, which will be Q times the order of the graph.

lower_bound

Numeric. Lower bound to the edge weights. The randomization process will avoid steps that would make edge weights fall outside this bound. It should generally be left as 0 to avoid negative weights.

weight_sel

Can be either const_var or max_weight.

n_reps

Number of samples of the rewired graph.

w_max

Numeric. Upper bound for edge weights. The randomization algorithm will avoid steps that would make edge weights fall outside this bound. Should be generally left as default (NULL), unless the network has by nature or by construction a known upper bound.

Value

A matrix with the results of each scoring function and algorithm. See table_style for details.


[Package clustAnalytics version 0.5.5 Index]