Dataset Viewer
The dataset viewer is not available for this dataset.
Unexpected token '<', "<html> <h"... is not valid JSON

Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.

Dataset Card for a-share-prices

Dataset Summary

This is a daily candlestick dataset of A-share 主板 market, covering the period Since January 1, 2005. It is primarily intended for historical market data research and does not guarantee the frequency of updates for new data. You can see the latest updated date in the file .last_update_date.

It consists in two files all-prices.csv and calendar.csv.

  • all-prices.csv is the primary data file(Attention: the prices are 不复权价).
  • calendar.csv is the extra file if you need to list the trade calendar.

You can load it with:

from datasets import load_dataset 
demo1 = load_dataset("ellendan/a-share-prices", data_files="all-prices.csv") 

Or manually download and save the csv files to local.

Dataset columns

The all-prices.csv file:

  • code,股票的代码
  • date,行情发生的日期。
  • open,开盘价。
  • low,最低价。
  • high,最高价。
  • close,收盘价。
  • prev_close,前一日收盘价。
  • quote_rate,涨跌幅(单位:%)。
  • volume,成交量(单位:手)。
  • turnover,成交额(单位:千元)。
  • high_limit,当日涨停的限价。
  • low_limit,当日跌停的限价。
  • turnover_rate,换手率(单位:%)。
  • turnover_rate_f, 自由流通换手率(单位:%)。
  • volume_ratio,量比。
  • pe,市盈率(总市值/净利润, 亏损的PE为空)。
  • pe_ttm,市盈率(TTM,亏损的PE为空)。
  • pb,市净率(总市值/净资产)。
  • ps,市销率。
  • ps_ttm,市销率(TTM)。
  • dv_ratio,股息率 (%)。
  • dv_ttm,股息率(TTM)(%)。
  • total_share,总股本 (万股)。
  • float_share,流通股本 (万股)。
  • free_share,自由流通股本 (万股)。
  • total_mv,总市值 (万元)。
  • circ_mv,流通市值(万元)。
  • name,股票中文名。
  • area,地域。
  • industry,所属行业。
  • market,市场类型(主板/创业板/科创板/CDR)。
  • exchange,交易所代码(SSE上交所 SZSE深交所 BSE北交所)。
  • list_date,上市日期。

因为切换了数据源,曾经旧的字段 is_stavg_price 不再提供。
is_paused字段,是否停牌 —— 数据集内都是“未停牌”的记录。

注意: 从2025年4月5日开始,all-prices.csv会增量更新,因此获取数据集后请手动排序(源csv文件不再保持 date 列的先后顺序)。

Downloads last month
855

Space using ellendan/a-share-prices 1