# Louvain-clustering
MATLAB simulation of clustering using Louvain algorithm, and comparing its performance with K-means.
Here is two sets of code.
----------------------------------------------------------------------------------------------------------------------------------
In the branch "clustering", the code set groups the nodes using Louvain (coded by us),
Louvain (code you recommend on Github) and K-means (from MATLAB, and it's Kmeans++, to be exact).
And the result of clustering is showed in figure 2, 3 and 4, respectively.
Figure 1 shows the initial postion of all nodes.
——>The main entrence of this code set is "clustering.m". <——
The function of the rest m files is listed as follows.
"cluster_jl.m" is the Louvain code from Github;
"dq.m" calculates the differences of Modularity Q after each iteration, using the term given in your paper;
"Louvain.m" is the main function of Louvain coded by us;
"modularity.m" calculates modularity Q;
"PPP.m" generates inital position of nodes following poisson distribution at the beginning of the programm;
"shrinkcluster.m" shrinks multiple nodes into a new one when it's need in the Louvain algorithm.
Parameters like numbers of cluster, average number of nodes, etc, can be modified in clustering.m.
----------------------------------------------------------------------------------------------------------------------------------
In the branch "compare", the code set compares the performances of Louvain algorithm with Kmeans.
There is only minor difference between the m files here and those in the clustering folder, that is all the functions
of plotting figure are commented because we don't need them here.
"CalcutaleP.m" calcutates the total and average transmit power using the result of clustering.
——>The main entrence of this code set is "compare.m".<——
The result is presented in the form of line chart and a sample chart is showed in
"sample.png" along with the code.
没有合适的资源?快使用搜索试试~ 我知道了~
温馨提示
matlab算法,工具源码,适合毕业设计、课程设计作业,所有源码均经过严格测试,可以直接运行,可以放心下载使用。有任何使用问题欢迎随时与博主沟通,第一时间进行解答! matlab算法,工具源码,适合毕业设计、课程设计作业,所有源码均经过严格测试,可以直接运行,可以放心下载使用。有任何使用问题欢迎随时与博主沟通,第一时间进行解答! matlab算法,工具源码,适合毕业设计、课程设计作业,所有源码均经过严格测试,可以直接运行,可以放心下载使用。有任何使用问题欢迎随时与博主沟通,第一时间进行解答! matlab算法,工具源码,适合毕业设计、课程设计作业,所有源码均经过严格测试,可以直接运行,可以放心下载使用。有任何使用问题欢迎随时与博主沟通,第一时间进行解答! matlab算法,工具源码,适合毕业设计、课程设计作业,所有源码均经过严格测试,可以直接运行,可以放心下载使用。有任何使用问题欢迎随时与博主沟通,第一时间进行解答! matlab算法,工具源码,适合毕业设计、课程设计作业,所有源码均经过严格测试,可以直接运行,可以放心下载使用。有任何使用问题欢迎随
资源推荐
资源详情
资源评论
收起资源包目录
毕业设计&课设-利用MATLAB仿真了Louvain算法的聚类,并将其性能与K-means进行了比较。.zip (16个子文件)
Louvain-clustering-master
compare
Louvain.m 2KB
compare.m 4KB
dq.m 502B
shrinkcluster.m 422B
modularity.m 536B
calculateP.m 655B
sample.png 58KB
PPP.m 754B
clustering
Louvain.m 2KB
dq.m 502B
cluster_jl.m 6KB
shrinkcluster.m 422B
clustering.m 2KB
modularity.m 536B
PPP.m 751B
README.md 2KB
共 16 条
- 1
资源评论
毕业小助手
- 粉丝: 2224
- 资源: 4366
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功