triangle_participation_ratio_communities: Triangle Participation Ratio (community-wise)

View source: R/scoring_functions.R

triangle_participation_ratio_communitiesR Documentation

Triangle Participation Ratio (community-wise)

Description

Computes the triangle participation ratio (proportion of vertices that belong to a triangle). The computation is done to the subgraphs induced by each of the communities in the given partition.

Usage

triangle_participation_ratio_communities(g, com)

Arguments

g

The input graph (as an igraph object). Edge weights and directions are ignored.

com

Community membership vector. Each element corresponds to a vertex of the graph, and contains the index of the community it belongs to.

Value

A vector containing the triangle participation ratio of each community.


clustAnalytics documentation built on May 29, 2024, 12:18 p.m.