当前位置:网站首页>并列图的画法,多排多列
并列图的画法,多排多列
2022-07-04 21:14:00 【小蜗笔记】
import matplotlib.pyplot as plt
plt.style.use('seaborn-whitegrid')
plt.rcParams['font.sans-serif']=['SimHei']
plt.rcParams['axes.unicode_minus'] = False
fig = plt.figure(figsize=(70, 60),dpi=60)
for i in range(1,42):
ax = fig.add_subplot(7,6,i)
ax.spines['bottom'].set_linewidth('1.0')#设置边框线宽为2.0
ax.spines['bottom'].set_color('black')
ax.spines['top'].set_linewidth('1.0')#设置边框线宽为2.0
ax.spines['top'].set_color('black')
ax.spines['right'].set_linewidth('1.0')#设置边框线宽为2.0
ax.spines['right'].set_color('black')
ax.spines['left'].set_linewidth('1.0')#设置边框线宽为2.0
ax.spines['left'].set_color('black')
plt.xticks(fontsize = 20)
plt.yticks(fontsize = 20)
plt.scatter(data_std_all[data_std_all['firm'] == i]['year'], data_std_all[data_std_all['firm'] == i]['tfpch'], c='black', edgecolors='black')
plt.plot(data_std_all[data_std_all['firm'] == i]['year'], data_std_all[data_std_all['firm'] == i]['y_forecast'],color='black',linestyle = '-',linewidth=2, markersize=12)
if len(data_std_all[(data_std_all['firm'] == i)&(data_std_all['group'] == 1)]['year']) !=0:
plt.plot([data_std_all[(data_std_all['firm'] == i)&(data_std_all['group'] == 1)]['year'].iloc[0],data_std_all[(data_std_all['firm'] == i)&(data_std_all['group'] == 1)]['year'].iloc[0]],[-2.5,2.5],
color='black',linestyle = '-.',linewidth=2, markersize=12)
plt.ylim(-3, 3)
plt.xlim(2009, 2022)
plt.xticks(size=30)
plt.yticks(size=30)
plt.title(data_std_all[data_std_all['firm'] == i]['area'].iloc[0],size=30)
plt.show()
边栏推荐
- [early knowledge of activities] list of recent activities of livevideostack
- Redis cache
- Flutter 返回按钮的监听
- At the right time, the Guangzhou station of the city chain science and Technology Strategy Summit was successfully held
- GTEST from ignorance to skillful use (1) GTEST installation
- 【活动早知道】LiveVideoStack近期活动一览
- 2021 CCPC Harbin B. magical subsequence (thinking question)
- Methods of improving machine vision system
- Interviewer: what is XSS attack?
- EhLib 数据库记录的下拉选择
猜你喜欢

TCP shakes hands three times and waves four times. Do you really understand?

Billions of citizens' information has been leaked! Is there any "rescue" for data security on the public cloud?

【LeetCode】17、电话号码的字母组合

Bookmark
![[optimtool.unconstrained] unconstrained optimization toolbox](/img/ef/65379499df205c068ee9bc9df797ac.png)
[optimtool.unconstrained] unconstrained optimization toolbox

迈动互联中标北京人寿保险

How is the entered query SQL statement executed?

Difference between ApplicationContext and beanfactory (MS)

WGCNA analysis basic tutorial summary

Maidong Internet won the bid of Beijing life insurance
随机推荐
How was MP3 born?
MongoDB聚合操作总结
【LeetCode】17、电话号码的字母组合
redis事务
2021 CCPC Harbin I. power and zero (binary + thinking)
Difference between ApplicationContext and beanfactory (MS)
【C語言】符號的深度理解
Liu Jincheng won the 2022 China e-commerce industry innovation Figure Award
【公开课预告】:视频质量评价基础与实践
Why does invariant mode improve performance
Acwing 2022 daily question
QT—绘制其他问题
Jerry's ad series MIDI function description [chapter]
Open3D 曲面法向量计算
Use of class methods and class variables
CloudCompare&Open3D DBSCAN聚类(非插件式)
new IntersectionObserver 使用笔记
Daily question-leetcode556-next larger element iii-string-double pointer-next_ permutation
Analysis of maker education technology in the Internet Era
刘锦程荣获2022年度中国电商行业创新人物奖