fig = plt.figure()
ax=plt.gca() timeList = np.array(timeList)
timeList=timeList*100
timeList1 = np.array(timeList1)
timeList1=timeList1*100
timeList2 = np.array(timeList2)
timeList2=timeList2*100
timeList3 = np.array(timeList3)
timeList3=timeList3*100
timeList4 = np.array(timeList4)
timeList4=timeList4*100
plt.plot(timeList,"go-",label="ratio-threshold=%d"%(threValue))
plt.plot(timeList1,"bs-",label="ratio-threshold=%d"%(threValue1))
plt.plot(timeList2,"r^-",label="ratio-threshold=%d"%(threValue2))
plt.plot(timeList3,"kp-",label="ratio-threshold=%d"%(threValue3))
plt.plot(timeList4,"m+-",label="ratio-threshold=%d"%(threValue4))
plt.yticks([0,2,4,6,8,10,12],['0%', '2%', '4%', '6%', '8%','10%', '12%'])
for label in ax.get_xticklabels():
label.set_rotation(90)
plt.xlabel("time axis")
plt.ylabel("ratio")
plt.title(r"Among 3/25-3/26 period")
plt.legend()
plt.show()
plt.plot(t1,"k--")
plt.plot(t2,"k--")
plt.plot(t3,"k--")
plt.plot(t4,"k--")
plt.plot(t5,"k--")
plt.annotate('25%', xy=(60, 10), xytext=(63, 12),arrowprops=dict(facecolor='black', shrink=0.05),)
plt.annotate('18%', xy=(60, 25), xytext=(63, 27),arrowprops=dict(facecolor='black', shrink=0.1),)
plt.annotate('13%', xy=(60, 50), xytext=(63, 52),arrowprops=dict(facecolor='black', shrink=0.1),)
plt.annotate('9%', xy=(60, 75), xytext=(63, 77),arrowprops=dict(facecolor='black', shrink=0.1),)
plt.annotate('8%', xy=(60, 100), xytext=(63, 102),arrowprops=dict(facecolor='black', shrink=0.1),)
plt.annotate('', xy=(0, 10), xytext=(-2, 12),)
plt.annotate('', xy=(0, 25), xytext=(-2, 27),)
plt.annotate('', xy=(0, 50), xytext=(-2, 52),)
plt.annotate('', xy=(0, 75), xytext=(-2, 77),)
plt.annotate('', xy=(0, 100), xytext=(-2, 102),)

matplotlib绘图的更多相关文章

  1. matplotlib 绘图

    http://blog.csdn.net/jkhere/article/details/9324823 都打一遍 5 matplotlib-绘制精美的图表 matplotlib 是python最著名的 ...

  2. python实战学习之matplotlib绘图续

    学习完matplotlib绘图可以设置的属性,还需要学习一下除了折线图以外其他类型的图如直方图,条形图,散点图等,matplotlib还支持更多的图,具体细节可以参考官方文档:https://matp ...

  3. matplotlib绘图的基本操作

    转自:Laumians博客园 更简明易懂看Matplotlib Python 画图教程 (莫烦Python)_演讲•公开课_科技_bilibili_哔哩哔哩 https://www.bilibili. ...

  4. python中利用matplotlib绘图可视化知识归纳

    python中利用matplotlib绘图可视化知识归纳: (1)matplotlib图标正常显示中文 import matplotlib.pyplot as plt plt.rcParams['fo ...

  5. matplotlib绘图基本用法-转自(http://blog.csdn.net/mao19931004/article/details/51915016)

    本文转载自http://blog.csdn.net/mao19931004/article/details/51915016 <!DOCTYPE html PUBLIC "-//W3C ...

  6. python实战学习之matplotlib绘图

    matplotlib 是最流行的Python底层绘图库,主要做数据可视化图表 可以将数据可视化,能够更直观的呈现数据 matplotlib绘图基本要点 首先实现一个简单的绘图 # 导入pyplot f ...

  7. 【原】在Matplotlib绘图中添加Latex风格公式

    Matplotlib绘图的过程中,可以为各个轴的Label,图像的Title.Legend等元素添加Latex风格的公式. 只需要在Latex公式的文本前后各增加一个$符号,Matplotlib就可以 ...

  8. Matplotlib绘图双纵坐标轴设置及控制设置时间格式

    双y轴坐标轴图 今天利用matplotlib绘图,想要完成一个双坐标格式的图. fig=plt.figure(figsize=(20,15)) ax1=fig.add_subplot(111) ax1 ...

  9. ssh调用matplotlib绘图报错RuntimeError: Invalid DISPLAY variable

    1.问题:在本地用matplotlib绘图可以,但是在ssh远程绘图的时候会报错 RuntimeError: Invalid DISPLAY variable 2.原因:matplotlib的默认ba ...

  10. Matplotlib绘图及动画总结

    目录 Matplotlib绘图总结 绘图原理 block模式(python默认) interactive模式(ipython模式默认) 深入子图 子图表示 子图绘图 绘制动画 参考链接 Matplot ...

随机推荐

  1. Shell脚本开发过程中遇到的问题处理

    1. 执行shell脚本报  Unsupported major.minor version 52.0 报错原因:java文件jdk和服务器上的jdk不匹配, 解决方法: a.查看当前服务器用的jdk ...

  2. VsCode之使用WebView通信

    之前我在这篇文章VsCode插件开发之插件初步通信 通过插件完成通信,这回我还是通过插件,只不过方式主要以在ts文件里面使用webview来进行通信. 另外在此声明,一定要好好看仔细看官方文档,国内关 ...

  3. vue-resource get/post请求如何携带cookie的问题

    vue-resource get/post请求如何携带cookie的问题 当我们使用vue请求的时候,我们会发现请求头中没有携带cookie传给后台,我们可以在请求时添加如下代码:vue.http.o ...

  4. 工具 使用Fiddler进行手机抓包

    Fiddler 手机抓包 Web代理服务器 可以抓https包 手机和电脑处于同一网络 Tools -> Options... -> Connections Allow remote co ...

  5. 循环神经网络RNN的基本介绍

    本博客适合那些BP网络很熟悉的读者 一 基本结构和前向传播 符号解释: 1. $c_{t}^{l}$:t时刻第l层的神经元的集合,因为$c_{t}^{l}$表示的是一层隐藏层,所以图中一个圆圈表示多个 ...

  6. IIC双向电平转换电路设计

    现代的集成电路工艺加工的间隙可达0.5μm 而且很少限制数字I/O 信号的最大电源电压和逻辑电平. 为了将这些低电压电路与已有的5V或其他I/O电压器件连接起来,接口需要一个电平转换器.对于双向的总线 ...

  7. springbootAdmin+eureka集群+swagger

    请移步githubb下载源码.知识共享.(https://github.com/yivvonllh) 或者直接git下载(https://github.com/yivvonllh/spring-clo ...

  8. Luogu P1265 公路修建

    一眼看去,就是一道MST的模板题. 然后果断准备跑Kruskal,然后5个TLE. Kruskal复杂度对于这个完全图要O(n^2*logn^2),快排就会导致超时. 然后打了刚学的Prim.朴素O( ...

  9. C#大型电商项目优化(二)——嫌弃EF与抛弃EF

    上一篇博文中讲述了使用EF开发电商项目的代码基础篇,提到EF后,一语激起千层浪.不少园友纷纷表示:EF不适合增长速度飞快的互联网项目,EF只适合企业级应用等等. 也有部分高手提到了分布式,确实,性能优 ...

  10. width,height为多少px时,A4纸打印时刚好一页?

    计算方式一般的分辨率为XX像素/英寸,其中一英寸为25.4毫米.所以一毫米的像素数就为XX/25.4.现在的工作就是求XX的值了,把XX的值求出来以后,直接用XX/25.4 * 210就得到A4纸的像 ...