graph_lcc: Largest connected component of a graph

Description Usage Arguments Examples

Description

Many graphs, including social networks, include a "giant component", meaning that most nodes in the network are connected to each other. Many network metrics (e.g. betweenness centrality) are only meaningful within a connected component, and connected graphs are easier to visualize. This function returns the largest (weakly) connected component of a graph.

Usage

1

Arguments

g

igraph graph object.

Examples

1
2
3
4
library(igraph)
g <- erdos.renyi.game(100,0.02)
lcc <- graph_lcc(g)
length(V(lcc))

ccjolley/cRimson documentation built on May 13, 2019, 2:16 p.m.