← Back to projects

Options Pricer

In progress
  • Python
  • pandas
  • scipy
  • yfinance

Overview

A Black-Scholes options pricer and Greeks calculator built from first principles in Python, feeding into a planned delta-hedging P&L simulator that compares implied vs. realized volatility — pricing an option, delta-hedging it over time using real historical price data, and decomposing the resulting P&L into its gamma, vega, and hedging-error components.

Pricing engineComplete

  • Closed-form Black-Scholes pricing for European calls and puts
  • Full Greeks: delta, gamma, vega, theta, rho
  • Validated against put-call parity and reference values

Note: theta and vega are returned in their natural units — theta per year, vega per 1.00 (100 percentage points) of volatility — rather than the "per day" / "per 1%" conventions used in market quoting.

Data pipelineIn progress

  • Historical daily price data pulled via yfinance, cached locally as CSV
  • Currently working with USO (oil ETF)
  • Next: log returns and annualized realized volatility from the price series

Currently a pandas pipeline, which I'll eventually move behind a small FastAPI service.

RoadmapNot started

  • Implied volatility (from market data, or an assumed input)
  • Delta-hedging simulation loop
  • P&L decomposition and analysis — gamma/theta/vega attribution, hedge-frequency sensitivity
  • Move the data pipeline behind a small FastAPI service, to compare realised vs. implied volatility directly against the pricing model's output

Status

Pricing engine complete and validated; data pipeline in progress; delta-hedging simulation and P&L decomposition not yet started. Built as part of ongoing quant finance preparation, alongside market-making theory.