zoukankan      html  css  js  c++  java
  • Clustering coefficient [转]

    Clustering coefficient的定义有两种;全局的和局部的。

    全局的算法基于triplet。首先解释triplet。
     
    triplet 包含 open triplet 和 closed triplet 两种(A triplet is three nodes that are connected by either two (open triplet) or three (closed triplet) undirected ties)
     
    例如下图{1,(2,3)}构成的triplet是封闭的,{3,(4,5)}构成的triplet是开放的
     
    1) Global Clustering Coefficient:
    Clustering coefficient(global) = number of closed triplet / number of triplet(closed+open)
     
    以上图为例:
    closed triplet ={1,(2,3)},{2,(1,3)},{3,(1,2)}
    all triplet = {1,(2,3)},{2,(1,3)},{3,(1,2)},{3,(2,4)},{3,(4,5)},{3,(1,5)},{3,(2,5)},{3,(1,4)}
    number of closed triplet = 3
    number of  triplet = 8
    number of triplet / number of  triplet = 3/8
     
    2) Local Clustering Coefficient:
    (1/n ) ∑ i=1:n |Ni|*(|Ni|-1)/2
    局部计算是面向节点的,对于节点vi,找出其直接邻居节点集合Ni,计算Ni构成的网络中的边数K,除以Ni集合可能的边数|Ni|*(|Ni|-1)/2
    例如:
    1节点的邻居节点(2,3),他们之间构成的边有1条,可能构成的边1条,因此1/1=1
    2节点的邻居节点(1,3),他们之间构成的边有1条,可能构成的边1条,因此1/1=1
    3节点的邻居节点(1,2,4,5),他们之间构成的边有1条,可能构成的边(4*3)/2条,因此1/6=1/6
    4节点的邻居节点(3),他们之间构成的边有0条,可能构成的边0条,因此0
    5节点的邻居节点(3),他们之间构成的边有0条,可能构成的边0条,因此0
     
    网络的平均聚类系数(network average clustering coefficient),5个节点平均local Clustering coefficient = (1+1+1/6)/5=13/30
     
    Cited from: http://blog.csdn.net/pennyliang/article/details/6838956
     
  • 相关阅读:
    开源项目
    ASP.NET上传文件带有真实的进度条
    VS2010不能调试的问题
    sql server 2005中获取数据库个数
    【转载】Nios II DMA: memory to memory
    【转】我们为什么要实习
    【转】应聘时最漂亮的回答
    【转】面试建议 每个要找工作的童鞋必看~
    【转载】FPGA Verilog HDL 系列实例 电子琴 电子钟
    【转】关于工作与生活 HP大中华区总裁孙振耀的退休感言
  • 原文地址:https://www.cnblogs.com/easoncheng/p/3715972.html
Copyright © 2011-2022 走看看