当前位置:网站首页>Commodity price visualization
Commodity price visualization
2022-07-06 05:58:00 【Twenty four bridges_】
import numpy as np
import matplotlib.pyplot as plt
plt.rcParams['font.sans-serif'] = ['SimHei']
plt.rcParams['axes.unicode_minus'] = False
with open('rb2010.csv', 'r', encoding='utf-8') as f:
file = f.readlines()[1:]
date = [i.strip().split(',')[0] for i in file]
settle = [int(i.strip().split(',')[5]) for i in file]
plt.grid(axis='both', color='k', linestyle='--', linewidth=1)
plt.xticks([i for i in range(len(date)) if i % 10 == 0], [i[-4:] for i in date[::10]], rotation=-30)
plt.yticks(np.arange(3200, 3801, 100))
plt.xlabel('2020 March to August ')
plt.ylabel(' Price ( element )')
plt.title(' Rebar futures trend chart ')
plt.plot(date, settle, linestyle='-', color='red', linewidth=1)
plt.savefig('rb2010p3.png')
plt.show()
边栏推荐
- (5) Explanation of yolo-v3 core source code (3)
- Station B Liu Erden - linear regression and gradient descent
- LTE CSFB process
- Rustdesk builds its own remote desktop relay server
- HCIA review
- Dynamic programming -- knapsack problem
- Practice sharing: how to safely and quickly migrate from CentOS to openeuler
- Yygh-11-timing statistics
- [Baiwen smart home] first day of the course_ Learn Embedded and understand the development mode of bare metal and RTOS
- Classes and objects (I) detailed explanation of this pointer
猜你喜欢
Station B Liu Erden softmx classifier and MNIST implementation -structure 9
Yygh-11-timing statistics
How can large websites choose better virtual machine service providers?
YYGH-11-定时统计
SQLMAP使用教程(三)实战技巧二
CoDeSys note 2: set coil and reset coil
类和对象(一)this指针详解
华为BFD的配置规范
Winter 2021 pat class B problem solution (C language)
(5) Explanation of yolo-v3 core source code (3)
随机推荐
Wib3.0 leapfrogging, in leapfrogging (ง • ̀_•́) ง
B站刘二大人-Softmx分类器及MNIST实现-Lecture 9
华为BFD的配置规范
嵌入式面试题(四、常见算法)
Analysis report on development trends and investment planning of China's methanol industry from 2022 to 2028
continue和break的区别与用法
Construction of yolox based on paste framework
Memory and stack related concepts
Bit operation rules
HCIA复习
ArcGIS application foundation 4 thematic map making
Report on the competition status and investment decision recommendations of Guangxi hospital industry in China from 2022 to 2028
MIT6.s081-2020 Lab2 System Calls
【LeetCode】Day96-第一个唯一字符&赎金信&字母异位词
Jushan database appears again in the gold fair to jointly build a new era of digital economy
Embedded interview questions (IV. common algorithms)
Auto. JS learning notes 17: basic listening events and UI simple click event operations
Demander le Code de texte standard correspondant à un centre de travail dans l'ordre de production
ContentType的作用
Pytorch代码注意的细节,容易敲错的地方