← All research notes

Drawdown across walk-forward fold boundaries

Losses can carry across evaluation folds while the account remains below an earlier peak. Resetting the drawdown calculation at a fold boundary discards that high and can understate the loss on the linked path.

The account marks below are invented to illustrate drawdown accounting.

Define drawdown on an ordered path

For positive wealth Wt, including its initial value, define the running high-water mark and the maximum drawdown magnitude as:

Ht = max0≤u≤t Wu
D = maxt [1 − Wt / Ht].

Here drawdown is a positive fractional loss measured from the running peak. Two paths with the same terminal return can have different drawdowns.

Discrete account marks only reveal losses at their observation times. A deeper loss between marks, or the fill of a stop order, needs finer observations and execution assumptions.

A worked boundary example

Take two folds, each with an initial wealth mark normalised to one and two later marks. In a walk-forward study, fitting and selection would precede each evaluation period.

Fold A has normalised marks 1.00, 1.10, 1.04. Its return is +4%, and its largest drawdown is 1 − 1.04/1.10 = 5.4545%. Fold B starts afresh with marks 1.00, 0.98, 0.95. Its return is −5%, and its largest local drawdown is 5.0000%.

First rescale the marks onto one path. The account-state discussion below considers when that path can represent a funded account.

Fold A’s final mark and Fold B’s initial mark represent the same boundary wealth in this example. Both rows are retained to show the local-to-linked accounting; they are not two distinct moments.

Multiply every Fold B mark by Fold A’s terminal gross return, 1.04, to put both folds on the same scale. The linked reference peak remains 1.10: Fold B has not recovered the high reached in Fold A.

Local marks and the linked running peak
Fold Mark Local normalised wealth Linked wealth Linked running peakLinked drawdown
A Initial 1.0000 1.0000 1.0000 0.00%
A Observation 1 1.1000 1.1000 1.1000 0.00%
A Observation 2 (boundary) 1.0400 1.0400 1.1000 5.45%
B Initial (same boundary) 1.0000 1.0400 1.1000 5.45%
B Observation 1 0.9800 1.0192 1.1000 7.35%
B Observation 2 0.9500 0.9880 1.1000 10.18%

What happens to a peak at the fold boundary?

Keep the six accounting rows fixed. Change whether the reference peak resets or carries into the next fold.

Maximum drawdown10.18%
Terminal wealth0.9880
The peak of 1.10 carries into Fold B. The final mark of 0.988 is 10.18% below it.0.961.041.12Fold AFold BLinked wealthSix accounting rows; one shared boundary
Linked account pathReference peak

The peak of 1.10 carries into Fold B. The final mark of 0.988 is 10.18% below it.

The six accounting rows come from the published CSV; the two boundary rows represent the same wealth. Local peaks are shown on the linked scale. Lines connect supplied marks and imply no observations between them.

Data and code
MarkWealthReference peakDrawdown
A start1.00001.00000.00%
A observation 11.10001.10000.00%
A observation 21.04001.10005.45%
B start1.04001.10005.45%
B observation 11.01921.10007.35%
B observation 20.98801.100010.18%
Static figure and caption
Six account marks with linked wealth, its running peak, and drawdowns measured from local and linked peaks.
Figure 1. The peak survives the fold boundary. Fold B starts below the linked path’s earlier peak. Resetting the reference peak hides part of the eventual drawdown: the maxima are 5.45% within folds and 10.18% when linked. Lines connect the six supplied marks in order; they do not supply an unobserved path between marks. Full-size figure.

The linked return is 1.04 × 0.95 − 1 = −1.20%. The linked maximum drawdown is 1 − 0.988/1.10 = 10.1818%. Reporting the worst local drawdown, 5.4545%, as the linked result would understate this example's peak-to-trough loss by 4.7273 percentage points.

State the conditions behind the comparison

For positive fold paths scaled by preceding terminal gross returns, with the same observations and fold-start funding marks included, the linked drawdown is at least as large as the worst local drawdown. The linked running peak includes each local peak after rescaling, and can additionally include an unrecovered earlier peak.

If Fold A ends at its peak instead, with marks 1.00, 1.10, 1.10, while Fold B remains 1.00, 0.98, 0.95, both drawdowns are 5%. The linked and worst local values can therefore be equal.

For general fold f, normalised path xf,k and fold return Rf:

Af = ∏j<f (1 + Rj)
Wf,k = Afxf,k.

Concatenate the rescaled observations in fold order and apply one running maximum. External cash flows, overlapping folds, or a return definition that disagrees with the final mark require a different accounting treatment.

Preserve state and observation conventions

When an account has several marks at the same timestamp, a stable event sequence may be needed to preserve their order. A pre-trade valuation and a post-cost valuation can differ even though their timestamps match. Deduplication by timestamp can remove an economically relevant observation.

Funding, valuation frequency, event order, fees and fold boundaries all belong in the account specification. Carrying the earlier peak changes the drawdown measurement without adding a transaction loss.

A reset fold may start with fresh cash and no positions. Multiplying its returns carries none of the previous fold’s inventory, settlement obligations or financing. For the linked path to represent one account, those transitions must already be consistent in the returns or be included in an account replay.

Reproduce the example

The script applies the running-peak definition to the printed six-mark example and the equality case. It needs no price data or strategy outputs.

Reproduce the figures

The figure script reproduces the charts from their published inputs. The figure data and checks record the inputs, seed and package versions.

python figures_v1.py --output-dir figures

Requires Python 3.10 or later, NumPy, SciPy and Matplotlib. Output: SVG and PNG in two layouts. Rendering varies with package versions; the supplied SVGs retain the published appearance.

Publication details

Assumes percentage returns and compounding.

PSIM-RN-03Revision:

Calculation checks (24 October 2026)