Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Fetches A-share and index candlestick data (daily, weekly, monthly, and 1-60 minute bars) via Sina and Tencent sources.
26% 83%+57 ptsof test cases passed
Passed 19 of 23 test cases with the skill, and 6 of 23 without it.
I need 100 bars of 1-minute high-frequency intraday data for Shanghai SSE Index (sh000001) via quote_data.py. Which frequency argument should be supplied?
Uses --freq 1m for 1-minute frequency
3 of 3 safety checks passed
Ashare 是 GitHub 上 3.2k Stars 的极简 A 股行情库,单文件、零配置、零注册。核心只有一个函数 get_price(),用新浪+腾讯双数据源自动切换,稳定性极高。
它的价值不在于数据丰富度(只有行情K线),而在于可靠性——当 akshare、efinance、adata 因为上游网站改版或反爬而暂时不可用时,Ashare 几乎总是能正常工作。
pip install requests pandas
无需安装额外包,requests 和 pandas 通常已存在于 Python 环境中。
唯一脚本:scripts/quote_data.py
# 日线(最近30天)
python quote_data.py quote --code sh000001 --count 30
# 周线
python quote_data.py quote --code sh600519 --freq 1w --count 20
# 月线
python quote_data.py quote --code sz000001 --freq 1M --count 12
# 5分钟线
python quote_data.py quote --code sh600519 --freq 5m --count 48
# 指定结束日期
python quote_data.py quote --code sh600519 --freq 1d --count 60 --end 2026-01-31
Skills that do similar work, with their benchmark result.
Next to this one in the catalogue, plus more from the same author.