How Many Nodes Are There?

node_count(x)

# S3 method for igraph
node_count(x)

# S3 method for network
node_count(x)

Arguments

x

<igraph> or <network>

Value

<integer>

Examples

ig <- example_igraph() node_count(ig)
#> [1] 5
nw <- example_network() node_count(nw)
#> [1] 5