Quant Memo
Advanced

The Cross-Entropy Method

The cross-entropy method finds rare events or optimizes a hard function by repeatedly sampling, keeping only the best-scoring samples, and refitting the sampling distribution to look more like those survivors — a simple loop that converges toward the region that matters.

Prerequisites: Monte Carlo Integration, Importance Sampling

Estimating the probability of a rare, extreme event — like a portfolio losing more than 40% in a week — by plain Monte Carlo simulation is painfully slow, because almost none of your randomly generated scenarios will land anywhere near that tail. The cross-entropy method speeds this up with a simple iterative trick: start with an ordinary sampling distribution, draw a batch of samples, keep only the small fraction that scored best (closest to the rare event or the optimum you're chasing), and refit the sampling distribution to match those survivors more closely. Repeat, and the sampling distribution gradually migrates toward the region that actually matters.

The name comes from the fact that at each step you're picking a new sampling distribution that minimizes the cross-entropy (a measure of how different two probability distributions are) between the current distribution and an idealized one that would sample only from the target region. In practice this reduces to a simple, closed-form update for common distribution families like the normal.

A worked example

To estimate the probability a portfolio return falls below −40% under a fitted model, start by sampling 10,000 scenarios from the base return distribution. Keep the worst-scoring 1% (the 100 most extreme draws) and refit a new sampling distribution — say, a normal distribution — to those 100 points, which will have a much more negative mean than the original. Sampling again from this shifted distribution produces far more scenarios near the −40% tail, letting the rare-event probability be estimated accurately with a fraction of the simulations plain Monte Carlo would need.

The cross-entropy method iteratively refits a sampling distribution toward whichever region scored best in the previous round, making it an efficient way to estimate rare-event probabilities or search for optima that plain uniform sampling would take vastly more simulations to find.

Related concepts

Practice in interviews

Further reading

  • Rubinstein & Kroese, The Cross-Entropy Method (2004)
ShareTwitterLinkedIn