惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Engineering at Meta
Engineering at Meta
罗磊的独立博客
Apple Machine Learning Research
Apple Machine Learning Research
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
有赞技术团队
有赞技术团队
小众软件
小众软件
GbyAI
GbyAI
J
Java Code Geeks
B
Blog
Blog — PlanetScale
Blog — PlanetScale
宝玉的分享
宝玉的分享
M
MIT News - Artificial intelligence
T
The Exploit Database - CXSecurity.com
Security Latest
Security Latest
阮一峰的网络日志
阮一峰的网络日志
NISL@THU
NISL@THU
T
Tenable Blog
S
Schneier on Security
T
Tor Project blog
V
V2EX
S
Secure Thoughts
P
Privacy International News Feed
Spread Privacy
Spread Privacy
博客园 - 三生石上(FineUI控件)
博客园_首页
T
Threatpost
月光博客
月光博客
Know Your Adversary
Know Your Adversary
Cyberwarzone
Cyberwarzone
T
The Blog of Author Tim Ferriss
H
Help Net Security
The Hacker News
The Hacker News
A
Arctic Wolf
B
Blog RSS Feed
雷峰网
雷峰网
The Last Watchdog
The Last Watchdog
S
SegmentFault 最新的问题
博客园 - 【当耐特】
Cisco Talos Blog
Cisco Talos Blog
Vercel News
Vercel News
Microsoft Security Blog
Microsoft Security Blog
A
About on SuperTechFans
P
Palo Alto Networks Blog
Attack and Defense Labs
Attack and Defense Labs
N
News | PayPal Newsroom
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
S
Securelist
L
LangChain Blog
I
InfoQ

博客园 - 遗忘海岸

简协运动模拟 电磁场中的运动轨迹模拟 圆周运动模拟 带阻力的平抛运动 C# 队列的一些并发模拟 devexpress gridview master,detail视图 focuseRowHandle 同步选中 C# Tcp Server端实现,使用TcpListener 深信服务超融合管理Api调用 GDI+画工作流图的一些总结 绘制贝塞而曲线 GDI+画直线带箭头 devexpress schedulerControl Gantt View 使用 逻辑回归损失函数求导 匀加速运动模拟python,(matplotlib) C# 实现排列 python 类鸟群Boids C#动态编译 正太分布数据排序后分段数据的方差与标准差 Android 的一个通用列表单选AlertDialog封装
matplotlim柱状图
遗忘海岸 · 2024-02-13 · via 博客园 - 遗忘海岸

import numpy as np
import matplotlib
matplotlib.use("TKAgg")
import matplotlib.pyplot as plt

d=np.arange(0,10,0.1)

datas=np.array( [24,10,13,36])
subjects=['香蕉','苹果','辣椒','其他']
plt.rcParams['font.family'] = 'SimHei' #调整中文乱码
plt.figure()
#plt.pie(datas,labels=subjects)
plt.bar(np.arange(len(subjects)), datas,width=0.15,tick_label=subjects,label='小红')
plt.bar(np.arange(len(subjects)) +0.15, datas * 1.2,width=0.15,label='小张')
plt.legend()
plt.title("水果数量比对")
plt.show()

View Code