Files
NewStock/code/data/daily_data.py
liaozhaorun 71c9496df8 init
2025-02-12 00:21:33 +08:00

11 lines
315 B
Python
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import tushare as ts
ts.set_token('3a0741c702ee7e5e5f2bf1f0846bafaafe4e320833240b2a7e4a685f')
pro = ts.pro_api()
import pandas as pd
import time
# 读取本地保存的股票列表 CSV 文件(假设文件名为 stocks_data.csv
df = ts.pro_bar(ts_code='000001.SZ', adj='hfq', start_date='20180101')
print(df)