NetworkX-simple graph
import networkx as nx
import matplotlib.pyplot
import scipy.io as sio
import numpy as np load_path='H:/summer/datasets_read/chb01/Seizure/cut/wc/03.mat'
load_data=sio.loadmat(load_path) # print(type(load_data))
# print(load_data.keys())
# print(load_data.values())
print(load_data['R']) Matrix=np.array(load_data['R'])
g = nx.Graph() for i in range(len(Matrix)):
for j in range(len(Matrix)):
g.add_edge(i,j) nx.draw(g)
matplotlib.pyplot.show()
Guess What?? Funny ,HA~

NetworkX-simple graph的更多相关文章
- networkX.core_number(graph)
今天在学习别人特征工程的时候,看到这样一个函数,max_kcore = pd.DataFrame(list(nx.core_number(graph).items()), columns=[" ...
- NetworkX系列教程(1)-创建graph
小书匠Graph图论 研究中经常涉及到图论的相关知识,而且常常面对某些术语时,根本不知道在说什么.前不久接触了NetworkX这个graph处理工具,发现这个工具已经解决绝大部分的图论问题(也许只是我 ...
- python复杂网络库networkx:基础
http://blog.csdn.net/pipisorry/article/details/49839251 其它复杂网络绘图库 [SNAP for python] [ArcGIS,Python,网 ...
- [LeetCode] Clone Graph 无向图的复制
Clone an undirected graph. Each node in the graph contains a label and a list of its neighbors. OJ's ...
- UVa 10720 - Graph Construction(Havel-Hakimi定理)
题目链接: 传送门 Graph Construction Time Limit: 3000MS Memory Limit: 65536K Description Graph is a coll ...
- 2013长沙 G Graph Reconstruction (Havel-Hakimi定理)
Graph Reconstruction Time Limit: 2 Seconds Memory Limit: 65536 KB Special Judge Let there ...
- FZU 2141 Sub-Bipartite Graph
Sub-Bipartite Graph Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u ...
- URAL 1320 Graph Decomposition(并查集)
1320. Graph Decomposition Time limit: 0.5 secondMemory limit: 64 MB There is a simple graph with an ...
- UVA 10720 Graph Construction 贪心+优先队列
题目链接: 题目 Graph Construction Time limit: 3.000 seconds 问题描述 Graph is a collection of edges E and vert ...
- HDU 2454 Degree Sequence of Graph G(Havel定理 推断一个简单图的存在)
主题链接:pid=2454">http://acm.hdu.edu.cn/showproblem.php?pid=2454 Problem Description Wang Haiya ...
随机推荐
- Unity 退出游戏 方法
Application.Quit(); 嗯,没错,这篇就这么短.
- div+css布局自适应小结
一.两栏布局(左定宽,右自动)1. float + margin即固定宽度元素设置float属性为left,自适应元素设置margin属性,margin-left应>=定宽元素宽度.举例: &l ...
- CF1041E Tree Reconstruction_构造_思维题
不难发现,每次询问结果一定是 (i,n)(i,n)(i,n), 而 iii 出现的次数恰好是 iii 到 i′i'i′ 的距离(i′i'i′ 是第一个不与 iii 相等的数).我们可以将这颗树构造成一 ...
- 【XSY2689】王子 - 网络流
复活!qwq 题目来源:2018冬令营模拟测试赛(九) 题意: [背景描述] 不是所有王子都会遇见自己的中关村,主公,公主. 从前有个王子姓王,王王子遇到了一位美丽的公主,她的名字当然是公公主 ...
- HTML 捕获window.close() 并做窗口关闭前的处理工作
转自:http://www.xinotes.net/notes/note/261/ <html> <head> <script language="JavaSc ...
- 数组的filter用法
filter() 方法创建一个新数组, 其包含通过所提供函数实现的测试的所有元素. 语法:var new_array = arr.filter(callback(element[, index[, a ...
- 硬核官宣:台积电官宣6nm及7nm加强版工艺!
台积电正式宣布了6nm(N6)工艺,在已有7nm(N7)工艺的基础上大幅度增强,号称可提供极具竞争力的高性价比,而且能加速产品研发.量产.上市速度. 这几年,曾经执行业牛耳的Intel在新工艺方面进展 ...
- JS生成数字加减乘法验证码
给大家分享一个简单的js验证码生成代码 PS:该代码依赖Jquery1.4版本以上 传入元素 如productionVerificationCode(#\(("a")) 反回验证码 ...
- Android开发进度04
1,今日:目标:实现登录和注册功能 2,昨天:完成登录和注册的界面以及后台数据库的操作 3,收获:会使用SQlite数据库的操作语句 4,问题:登录时出现问题(登录不上去)
- spring mvc 下载的时候中文文件名不显示
Headers.add("Content-Disposition", "attachment;filename=" + new String(file.getB ...