Package 'VertexSimilarity'

Title: Creates Vertex Similarity Matrix for an Undirected Graph
Description: Creates Vertex Similarity matrix of an undirected graph based on the method stated by E. A. Leicht, Petter Holme, AND M. E. J. Newman in their paper <DOI:10.1103/PhysRevE.73.026120>.
Authors: Rishabh Singh
Maintainer: Rishabh Singh<[email protected]>
License: GPL-2
Version: 0.1
Built: 2024-10-29 06:19:07 UTC
Source: CRAN

Help Index


Vertex Similarity

Description

Returns Vertex Similarity matrix of undirected grahp based on the method stated by E. A. Leicht, Petter Holme, AND M. E. J. Newman <DOI:10.1103/PhysRevE.73.026120>

Usage

VertexSimilarity(m,alpha=0.97)

Arguments

m

Adjacency matrix of the graph

alpha

It tells the contribution of long paths relative to short ones.For, 0 < alpha < 1, similarity measure considers vertices to be more similar if they have a greater than expected number of short paths between them, than if they have a greater than expected number of long ones.

Details

This method is based on the idea that a pair of vertices i,j are similar to each other if any pair u,v of their neighbours is similar. Using this method we can even find similarity values for the vertices that are not directly connected.

Examples

m <- matrix(c(1,0,0,0,0,1,1,1,1),ncol=3,nrow=3,byrow=TRUE)
SimilarityMatrix <- VertexSimilarity(m,alpha=0.85)