# 日次空売り出来高の取得

get_daily_short_volume(stock_code, next_key=None, num=None)

  • 説明

    米国株または香港株の日次空売り出来高データを取得します。ページネーションをサポートしています。

  • パラメータ

    パラメータ 説明
    stock_code str 銘柄コード
    next_key str ページネーションキー
    num int 1ページの件数
  • 戻り値

    パラメータ 説明
    ret RET_CODE API 呼び出し結果
    us_df pd.DataFrame 米国株の日次空売りデータ。ret != RET_OK の場合はエラー文字列
    hk_df pd.DataFrame 香港株の日次空売りデータ。ret != RET_OK の場合は None
    • 米国株 DataFrame(us_df)フィールド説明:

      フィールド 説明
      timestamp int 取引日タイムスタンプ(秒単位の Unix タイムスタンプ、当日 0 時)
      timestamp_str str 取引日文字列
      total_shares_short int 空売り総株数
      nasdaq_shares_short int NASDAQ 空売り株数
      nyse_shares_short int NYSE 空売り株数
      short_percent float 空売り比率
      volume int 出来高(株)
      close_price float 終値
      last_close_price float 前回終値
      daily_trade_avg_ratio float 日次平均出来高比率
    • 米国株 us_df.attrs 追加属性:

      属性 説明
      next_key str ページネーションキー
    • 香港株 DataFrame(hk_df)フィールド説明:

      フィールド 説明
      timestamp int 取引日タイムスタンプ(秒単位の Unix タイムスタンプ、当日 0 時)
      timestamp_str str 取引日文字列
      shares_traded int 出来高(株)
      turnover float 売買代金
      short_sell_shares_traded int 空売り出来高(株)
      short_sell_turnover float 空売り売買代金
      open_price float 始値
      close_price float 終値
      last_close_price float 前回終値
      daily_trade_avg_ratio float 日次平均出来高比率
    • 香港株 hk_df.attrs 追加属性:

      属性 説明
      next_key str ページネーションキー
      aggregated_short int 未決済空売り株数
      aggregated_short_ratio float 流通株比率
      new_time_str str 最新データ時刻
  • Example

from moomoo import *
quote_ctx = OpenQuoteContext(host='127.0.0.1', port=11111)

ret, us_df, hk_df = quote_ctx.get_daily_short_volume("HK.00700")
if ret == RET_OK:
    print(hk_df)
else:
    print('error:', hk_df)
quote_ctx.close()
1
2
3
4
5
6
7
8
9
  • Output
timestamp timestamp_str  ...  last_close_price  daily_trade_avg_ratio
0  1778169600    2026-05-08  ...             477.4                  11.36
1  1778083200    2026-05-07  ...             463.0                  11.80
2  1777996800    2026-05-06  ...             472.2                  12.22
3  1777910400    2026-05-05  ...             473.0                  12.76
4  1777824000    2026-05-04  ...             467.8                  13.02
5  1777478400    2026-04-30  ...             479.2                  13.09
6  1777392000    2026-04-29  ...             473.8                  14.02
7  1777305600    2026-04-28  ...             478.6                  14.13
8  1777219200    2026-04-27  ...             493.4                  14.14
9  1776960000    2026-04-24  ...             495.2                  14.18

[10 rows x 10 columns]
1
2
3
4
5
6
7
8
9
10
11
12
13

制限事項

  • 30 秒以内に最大 30 回のリクエストが可能です。
  • 香港株・米国株の普通株およびファンドに対応しています。