Skip to content
All library documents

Option Quoting with Vega-Adjusted Spreads and Position Limits

Code Quant course library

Summary

This option algorithm combines reference-price calculation with a two-sided quoting and opportunistic execution rule. It sets a minimum price spread and a volatility-based spread proportional to the option’s cash vega, then uses the larger value to place bid and ask prices around the reference. When trading is active, it checks the best opposing quote: it seeks a long position if the ask is at or below its bid, and a short position if the bid is at or above its ask. Order size is capped by displayed top-of-book volume, a maximum order size, and the remaining room around a target position.

The algorithm separates pricing from trading, supports long and short permissions, and cancels active orders on a timer or when trading stops. It also offsets orders against existing opposite-side positions before opening a new position. The document is code only: it supplies no backtest, execution analysis, calibration guidance, or evidence that the quoting rules are profitable. Results would depend on option pricing inputs, market conditions, latency, and position settings.

Key ideas

  • The quoted spread is the greater of a minimum price spread and a cash-vega-scaled spread.
  • Bid and ask quotes are placed around a calculated option reference price.
  • The algorithm trades when the opposing best quote reaches its own displayed quote.
  • Trade size is constrained by top-of-book volume, an order cap, and target-position limits.
  • Existing opposing positions are reduced before new exposure is opened.

Tags

From a private course collection; the original is not published.