n_edges: Get Number of Edges

View source: R/class-network.R

n_edgesR Documentation

Get Number of Edges

Description

Returns the number of edges in a cograph_network.

Usage

n_edges(x)

Arguments

x

A cograph_network object.

Value

Integer: number of edges.

See Also

as_cograph, n_nodes

Examples

mat <- matrix(c(0, 1, 1, 1, 0, 1, 1, 1, 0), nrow = 3)
net <- as_cograph(mat)
n_edges(net)  # 3

cograph documentation built on May 31, 2026, 5:06 p.m.