centralities {tna}R Documentation

Calculate Centrality Measures for a Transition Matrix

Description

Calculates several centrality measures. See 'Details' for information about the measures.

Usage

centralities(x, loops = FALSE, normalize = FALSE, measures, ...)

## S3 method for class 'tna'
centralities(x, loops = FALSE, normalize = FALSE, measures, ...)

## S3 method for class 'matrix'
centralities(x, loops = FALSE, normalize = FALSE, measures, ...)

## S3 method for class 'group_tna'
centralities(x, loops = FALSE, normalize = FALSE, measures, ...)

Arguments

x

A tna object, a group_tna object, or a square matrix representing edge weights.

loops

A logical value indicating whether to include loops in the network when computing the centrality measures (default is FALSE).

normalize

A logical value indicating whether the centralities should be normalized (default is FALSE).

measures

A character vector indicating which centrality measures should be computed. If missing, all available measures are returned. See 'Details' for available measures. The elements are partially matched ignoring case.

...

Ignored.

Details

The following measures are provided:

Value

A tna_centralities object which is a tibble (tbl_df). containing centrality measures for each state.

See Also

Centrality measure functions betweenness_network(), plot.group_tna_centralities(), plot.tna_centralities(), print.group_tna_centralities(), print.tna_centralities()

Examples

model <- tna(group_regulation)

# Centrality measures including loops in the network
centralities(model)

# Centrality measures excluding loops in the network
centralities(model, loops = FALSE)

# Centrality measures normalized
centralities(model, normalize = TRUE)


[Package tna version 1.0.0 Index]