Skip to content
All library documents

Optimal Entry, Exit, and Switching with an Exponential OU Model

Article Stratmill research code

Summary

This technical guide models a positive mean-reverting portfolio as the exponential of an Ornstein–Uhlenbeck process. It fits the model by maximizing average log-likelihood, selecting the portfolio asset ratio that produces the best fit. The model parameters describe the long-run mean, reversion speed, and volatility. For a single entry and exit, it formulates discounted optimal-stopping problems with separate entry and liquidation costs, then derives threshold rules: enter within an optimal interval and liquidate at an optimal upper level.

The guide extends the framework to repeated trading through an optimal-switching problem, including conditions under which re-entry is worthwhile. It describes fitting data, calculating levels, and plotting them, and gives a simulation example. The framework assumes a mean-reverting portfolio and specified discount rates and transaction costs; the stopping formulation also presumes only one entry and one liquidation. The excerpt offers mathematical procedures rather than empirical proof of profitability, and results depend on model fit and assumptions.

Key ideas

  • The XOU model represents a positive portfolio value as the exponential of an OU process.
  • Model fitting maximizes log-likelihood and selects the asset ratio with the strongest fitted likelihood.
  • The single-trade formulation uses an entry interval and a liquidation threshold after accounting for costs and discounting.
  • An optimal-switching formulation allows repeated entries and exits when stated re-entry conditions hold.
  • The method relies on a mean-reverting model and does not provide empirical evidence of profitability.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.