distinctiveness {distinctiveness}R Documentation

The main function; oversees the calculations of Distinctiveness Centrality

Description

The main function; oversees the calculations of Distinctiveness Centrality

Usage

distinctiveness(
  G,
  alpha = 1,
  normalize = FALSE,
  measures = c("D1", "D2", "D3", "D4", "D5")
)

Arguments

G

the given graph

alpha

the given exponent for penalizing connections to highly connected nodes

normalize

when TRUE, the function normalizes output metrics to allow for comparison with other graphs. Defaults to FALSE

measures

the measures of Distinctiveness Centrality to be computed

Value

a data frame containing the specified calculated measures of Distinctiveness Centrality for the given graph

Examples


g <- igraph::erdos.renyi.game(20, 50, type = "gnm", directed = FALSE)
plot(g)
distinctiveness(g)
distinctiveness(g, alpha = list(2, 1, 3, 2, 4), measures = c("D1", "D3", "D4"))

g_dir <- igraph::erdos.renyi.game(20, 50, type = "gnm", directed = TRUE)
plot(g_dir)
distinctiveness(g_dir)
distinctiveness(g_dir, alpha = 2, normalize = TRUE, measures = c("D2", "D5"))


[Package distinctiveness version 1.0.1 Index]