Deep Hedge

Reading time: 11 minutes

Inspired by recent ongoings in the literature of reinforcement learning, we constructed a highly modular framework for hedging a portfolio of derivatives in the presence of unpleasant market frictions and imperfections. The idea behind the framework is to encourage future research projects by reducing the setup costs. It reduces the cost to the extent that even undergraduate students are now able to set up small research projects using our framework. All without the need to implement any OpenAI environments or extensive Tensorflow models – basic Python and statistics knowledge are sufficient.
The most vanilla derivative is a European option – its payoff X can be defined as following:

 X=f(S_T))=\left{\begin{matrix} &S_T-K&, S_T>K \\  &0&,S_T\leq K \end{matrix}\right.

We can then perfectly hedge the derivative X with a self-financing portfolio \pi we if:

P \left[ \pi_{t-1}^0 B_t+\pi_{t-1}^1S_t = X \right]=1

where S_t is the stock price and B_t the bond price. The portfolio \pi=(\pi)^T_{t=0} is a sequence of random vectors \pi_t=(\pi_t^0,\pi_t^1) denoting the units of shares and bonds. The portfolio \pi_t needs to satisfy the adaptness condition, where \pi_t=f_t(S_0,S_1,…S_t) for some measurable function f_t:(0,\inf)\rightarrow  \mathbb{R}^2. The performance of the hedging strategy can be measured via the resulting hedging error for the specific portfolio \pi:


where V_0^\pi is defined as the initial cash injection to hedge the liability -X. Due to the required time-discretization we observe a non-zero hedging error. As the the discrete time steps increase, the hedging error converges to 0.

The Black-Scholes (BS) model delivers a (theoretical) perfect hedge by holding a delta proportion of the underlying. The BS model is the industry’s standard when it comes to derivative-pricing, even though it is built on very strong assumptions such as:

  • constant riskless return
  • the stock follows a BM with a constant drift and volatility
  • no dividends are paid
  • no arbitrage opportunity
  • unlimited borrowing and lending of any amount, even fractional, of cash at the riskless rate
  • unlimited buy and sell of any amount, even fractional, of the stock
  • no transaction costs

Starting from the Black-Scholes price for a European call option at time t with time to maturity T-t:



d_1=\frac{1}{\sigma\sqrt{T-t}}\left[ln\left(\frac{S_t}{K} \right)+(r+\frac{\sigma^2}{2}(T-t))\right]
d_2=d_1- \sigma \sqrt{T-t}

and N(\cdot) is the standard normal CDF.
The derivative of C(S_t,t) with respect to the underlying asset, returns the respective rate of change of the theoretical option value:

\Delta=\frac{\partial C}{\partial S}=N(d_1)

In continuous time, this allows one to perfectly hedge the derivative by holding delta proportion of the underlying. In practice, the continuous time hedging is not feasible and the BS delta needs to be approximated at each point in time. This is where our our deep learning model comes into play.

We first construct a generic market environment based on Black-Scholes simulated data:

S_t=S_0e^{\mu-\frac{\sigma^2}{2}t+\sigma W_t}

where W_t is following a geometric Brownian motion. The stock paths are simulated 100.000 times where each path consists of 90 time-steps. The maturity of the European Option is +90 days. The initial setup is modified by slight variations in the options’ moneyness, implied volatility and drift.

Then, we construct a neural net that is capable of capturing the sequential structure of the data. For the simulated data, this might be overkill, but it will be handy when applying the model to empirical data. The output of the model is the hedging strategy itself, while the cost function is the conditional Value-at-Risk based on the PnL from the portfolio.

The first results from the training, imply that the model is able to replicate the performance of the ground-truth model.

In the future we would like to see how such a model-free and data-driven approach performs on empirical data. It can be easily extended to multiple risk-factors and risk objectives. We are also eager to test its capabilities within a scenario-based testing routine reflecting different market environments.

Print Friendly, PDF & Email