# 期权合约排行

get_option_rank(option_market, sort_type, count=None, trading_date=None, sort_direction=None, page=None, filter_list=None)

  • 介绍

    获取期权合约排行列表,支持按成交量、持仓量、增仓量、减仓量、IV、涨跌幅等维度排序。

  • 参数

    参数 类型 说明
    option_market OptionMarket 期权市场类型
    sort_type OptionRankType 排序类型
    count int 返回数量
    trading_date str 交易日
    sort_direction int 排序方向
    page str 分页游标
    filter_list list[OptionRankFilter] 筛选条件列表
  • 返回

    返回四元组 (ret, data, next_page, all_count)

    参数 类型 说明
    ret RET_CODE 接口调用结果
    data pandas.DataFrame 当 ret == RET_OK,返回排行数据
    data str 当 ret != RET_OK,返回错误描述
    next_page str 下一页游标,None 表示无更多数据
    all_count int 满足筛选条件的总数量
    • data DataFrame 字段:

      字段 类型 说明
      code str 期权合约代码
      name str 期权名称
      option_type str 期权类型
      oi_increment int 增仓量(>=0)
      oi_decrement int 减仓量(>=0)
      oi_market_cap_increment float 增仓额(>=0)
      oi_market_cap_decrement float 减仓额(>=0)
      volume int 成交量
      turnover float 成交额
      open_interest int 持仓量
      open_interest_market_cap float 持仓额
      iv float 隐含波动率(百分比)
      option_price float 期权最新价
      change_ratio float 涨跌幅(小数)
      mid_price float 中间价
      bid_price float 买入价
      bid_volume int 买量
      ask_price float 卖出价
      ask_volume int 卖量
      delta float Delta
      gamma float Gamma
      theta float Theta
      vega float Vega
      rho float Rho
      trading_date str 排行数据对应交易日
      trading_timestamp float 排行数据对应交易日时间戳(Unix 秒)
  • Example

from futu import *

quote_ctx = OpenQuoteContext(host='127.0.0.1', port=11111)

ret, data, next_page, all_count = quote_ctx.get_option_rank(
    OptionMarket.US_SECURITY,
    OptionRankType.VOLUME,
    count=5
)
if ret == RET_OK:
    print(data)
    print('all_count:', all_count)
else:
    print('error:', data)

quote_ctx.close()
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
  • Output
                  code                name option_type  oi_increment oi_decrement  oi_market_cap_increment oi_market_cap_decrement  volume    turnover  open_interest  open_interest_market_cap       iv  option_price  change_ratio  mid_price  bid_price  bid_volume  ask_price  ask_volume    delta    gamma      theta     vega  rho trading_date  trading_timestamp
0  US.SPY260612C742000  SPY 260612 742.00C        CALL          1816          N/A                 105328.0                     N/A  730160  91928623.0           7449                  432042.0  146.507          0.58       -67.688      0.580       0.56          28       0.60           1  0.43674  0.27447 -455.46028  0.00385  0.0   2026-06-12       1.781237e+09
1  US.SPY260612C745000  SPY 260612 745.00C        CALL          5416          N/A                   5416.0                     N/A  617981  44479304.0          17013                   17013.0   87.067          0.01       -98.958      0.015       0.01         708       0.02         500  0.02438  0.03501  -18.52310  0.00107  0.0   2026-06-12       1.781237e+09
2  US.SPY260612C743000  SPY 260612 743.00C        CALL          5438          N/A                  48942.0                     N/A  606769  64419534.0           7426                   66834.0   59.082          0.09       -93.898      0.095       0.09         208       0.10         118  0.13412  0.19487  -50.92453  0.00405  0.0   2026-06-12       1.781237e+09
3  US.SPY260612P740000  SPY 260612 740.00P         PUT          1223          N/A                   1223.0                     N/A  566915  69291991.0          15291                   15291.0   53.083          0.01       -99.790      0.015       0.01         447       0.02         407 -0.03761  0.08224  -16.47701  0.00153  0.0   2026-06-12       1.781237e+09
4  US.SPY260612C741000  SPY 260612 741.00C        CALL          2924          N/A                 423980.0                     N/A  506505  88981079.0           6229                  903205.0  224.448          1.45       -33.179      1.520       1.46          12       1.58          23  0.63754  0.17055 -662.49947  0.00367  0.0   2026-06-12       1.781237e+09
all_count: 1955829
1
2
3
4
5
6
7

接口限制

  • 30 秒内最多请求 60 次期权合约排行接口(支持分页的接口,仅首次调用纳入统计)