ntriangles: ntriangles

View source: R/compareMetrics.R

ntrianglesR Documentation

ntriangles

Description

Calculate number of triangles of a network

Usage

ntriangles(x)

Arguments

x

square matrix (adjacency matrix)

Details

This function calculates the number of triangles in a network given an adjacency matrix. We use igraph for this.

Value

scaler, number of triangles

Author(s)

Abhirup

Examples

ntriangles(beach[[1]][, ])

dnr documentation built on March 10, 2026, 9:06 a.m.