程序師世界是廣大編程愛好者互助、分享、學習的平台,程序師世界有你更精彩!
首頁
編程語言
C語言|JAVA編程
Python編程
網頁編程
ASP編程|PHP編程
JSP編程
數據庫知識
MYSQL數據庫|SqlServer數據庫
Oracle數據庫|DB2數據庫
您现在的位置: 程式師世界 >> 編程語言 >  >> 更多編程語言 >> Python

Extracting stock data with Python and extracting data through tushare API interface

編輯:Python

First step , register tushare

https://tushare.pro/register

The second step , Improve personal information , get 20 integral .

Registered successfully 100 branch , Perfect information 20 branch , Only 120 The data interface can only be called after a minute .

The third step , Write code .

Copying code piece by piece is too much trouble , I'll just go straight to my python The package link is ready .
https://download.csdn.net/download/m0_37263074/20971055

The database operation involved here needs to be changed to your database address , I use it mysql

Step four , install python modular , Let the project not report errors .

All the modules inside can be used
pip install time (time For example , Install the corresponding module according to the module name used inside )

Step five , Get your token, Fill in main.py Inside the document

Step six , Run test

Good configuration python Operation procedure of , Can run 了

Step seven , Check the data

Check whether the tables of the database have been established , Is the data correct

win-win

The code uses my user's token, If you don't want to change token You can use it directly . The higher the score , The greater the data permissions that can be invoked . therefore , I suggest you see here , Together to maintain this token, The maintenance method is very simple , You can register through the following link ( Same as the opening link ).
https://tushare.pro/register
I contribute code , You contribute points , We all share token, This is a win-win situation in the new era @[email protected]
If you have any questions about the code, please leave a message , Reply when you see . You can also add wechat to communicate , Let's make progress together !


  1. 上一篇文章:
  2. 下一篇文章:
Copyright © 程式師世界 All Rights Reserved