Two portfolios fall equally far. One takes years to recover.
Measure drawdown duration, recovery time and unfinished episodes. Compare portfolio paths without hiding calendar gaps, cash flows or the longest unresolved loss.

The loss is familiar; the waiting is not
The report says that both portfolios suffered a ten-percent maximum drawdown. Their owners remember completely different experiences. One watched a quick decline, a difficult fortnight and a recovery. The other spent eighteen months below a previous high, making the same monthly review with no new peak to record. The depth statistic is not wrong. It simply leaves out the part of the experience measured by a calendar rather than by money.
That missing dimension matters when reviewing a trading robot. A system can have modest observed drawdowns but long stretches without recovering a prior peak. Another can recover quickly from several declines while suffering a deeper isolated loss. Neither description automatically makes one preferable. They establish different research questions about the timing of gains, the persistence of losses, the capital committed and the feasibility of following the stated process.
Drawdown depth and drawdown duration are different measurements of the same path. A useful report preserves both. It also distinguishes a finished historical recovery from a decline still in progress at the end of the data. Calling the latter a short episode because the file stops would convert missing future information into a favorable result.
The examples below are invented teaching paths. They are not forecasts, records of an account or results of the TradeAndRoll demo. We will define the clock, trace each episode by hand and identify the assumptions that change the answer. The aim is to make duration an inspectable property of the evidence you have, while resisting the temptation to turn historical waiting times into a promise about the next recovery.
Decide what is climbing before measuring its peaks
Drawdown needs a series whose running maximum has a clear meaning. That could be account equity marked at each daily close, a cumulative return index adjusted for external cash flows, or another explicitly defined measure. These series can reach peaks on different dates. A deposit raises raw equity without representing trading profit; an open losing position lowers equity before it affects a realized-balance curve.
For our main example, use a hypothetical investment index with no external flows, observed at the end of every numbered session. It starts at 100. At each session, its running high is the greatest index level observed so far, including the current observation. Percentage drawdown is current index divided by that running high, minus one. At a high it is zero; below a high it is negative.
Suppose the levels are 100, 110, 108, 99, 103, 107 and 110. After the second observation the running high is 110. The level of 99 represents a ten-percent drawdown because 99 divided by 110 is 0.9. Returning to 110 restores the previous high even though the path has not exceeded it. Whether equality ends the episode is a convention that must be stated rather than left to a hidden comparison operator.
In this article reaching or exceeding the previous peak ends an episode. The first later observation below a peak marks entry into the underwater state. We measure elapsed duration from the peak observation to the first recovery observation. This makes the peak a boundary, not a losing session. Other definitions can be useful, but numbers produced under different conventions should not be placed in one table as if they were identical.
The literature explicitly treats the temporal dimension of drawdown as distinct from its magnitude. Ola Mahmoud’s paper formalizes duration as time spent on excursions below a running maximum. The Temporal Dimension of Risk. Our discussion uses original small paths to illustrate reporting decisions; it does not reproduce the paper’s empirical findings or claim that those findings validate a trading product.
Give the episode three dates, not one length
A complete drawdown episode has a peak date, a trough date and a recovery date. The interval from peak to trough describes the descent. The interval from trough to recovery describes the subsequent recovery. The full episode runs from peak to recovery. These lengths answer different questions, even when a software report labels all of them recovery time.
In the seven-observation example, number sessions from zero through six. The peak of 110 occurs at session one, the trough of 99 at session three, and recovery at session six. Descent lasts two session intervals, recovery from the trough lasts three, and the full peak-to-recovery duration is five. There are four strictly underwater closing observations: sessions two, three, four and five. Five elapsed intervals and four underwater observations are both correct, but they are not the same count.
If the trough appears twice, choose and disclose a convention. For example, levels of 99 at sessions three and four produce the same maximum depth but a choice between the first and last trough as the recovery starting point. Selecting the last trough shortens the reported trough-to-recovery time. Our main episode duration remains unchanged because its boundaries are the prior peak and the first recovery.
Always distinguish elapsed intervals from the number of underwater observations. Many apparent disagreements between spreadsheets are off-by-one conventions. They can usually be resolved by displaying the relevant dates and values. A single duration column hides the evidence needed to understand the difference, while three dates make the calculation inspectable without trusting a particular library.
The distinction is practical when a robot trades intermittently. A descent lasting two sessions may contain one trade or twenty. A three-session recovery may involve new profitable trades, reversal of an open loss or no action until a previously held position changes value. Duration alone does not identify the mechanism, so preserve the position and return records alongside the episode table.
Equal depth can contain very different histories
Construct portfolio A from six session levels: 100, 95, 90, 94, 98 and 100. Its maximum drawdown is ten percent and its first complete episode lasts five intervals. Portfolio B starts at 100, falls to 90 and then stays below 100 until session twenty, when it finally reaches the previous high. It has the same maximum depth but a twenty-interval episode under the same observation convention.
The paths do not tell us that B has a weaker future edge. They tell us that its observed return sequence delivered recovery later. A low-frequency strategy can have long quiet stretches because its opportunities are infrequent. A different strategy can remain underwater because its losses cluster. Yet another can appear stagnant because stale valuation marks smooth the series. The duration is a symptom to investigate, not a diagnosis by itself.
Now hold final return and maximum drawdown fixed while rearranging gains and losses. If profits arrive early and losses late, the sample can end inside an unfinished drawdown. If the same losses arrive first and gains later, the sample can contain a complete recovery. Summary return and depth may look similar, but the episode inventory changes. This is one reason the chronological order of returns is essential when examining waiting time.
It also explains why sorting trades from worst to best is not a harmless visual exercise. A sorted sequence creates a path the strategy did not experience. It might illustrate a deliberately constructed stress ordering, but its duration belongs to that artificial arrangement. Keep the original chronological result and the stress result separately labeled, with the transformation described precisely.
A comparison should therefore show the longest completed episode, the current unfinished episode, the proportion of observed time below a high and a small set of dated paths. Those views reveal whether a striking maximum duration describes one unusual event or a broader pattern of spending most of the sample below earlier peaks.
A calendar day is not a trading observation
Imagine a portfolio peaks on Friday evening, falls below that peak on Monday and recovers on Tuesday. From Friday to Tuesday, four calendar days have elapsed. Depending on the market calendar and observation definition, only two trading-session intervals may have elapsed. If the report says four days without naming the clock, a reader can easily compare it with another report using session counts and infer a difference that does not exist.
Calendar time describes the owner’s waiting period. Session time describes elapsed opportunities to observe or trade under a specified calendar. Trade count describes how many completed decisions occurred. None is automatically the right answer for every purpose. A weekly strategy can spend many calendar days underwater while executing only a few trades; an intraday strategy can experience hundreds of decisions during the same wait.
For irregular timestamps, calculate elapsed time from the actual instants rather than multiplying row counts by an assumed interval. A missing data block should not vanish from the owner’s calendar merely because the CSV has no rows for it. Conversely, filling a weekend with repeated values creates extra observations without creating additional market activity. The duration calculation must know which clock those rows are meant to represent.
Report at least one explicitly named clock. If the intended reader cares about capital availability over months, calendar duration is often informative. If the researcher is comparing signal opportunities, session and trade counts can complement it. A clear table might state calendar days, observed sessions and closed trades for each episode, while preserving the original peak and recovery timestamps.
The same issue appears around daylight saving changes and different broker session boundaries. A daily close defined in one time zone may shift relative to another. The article on market timestamps explains why a timestamp is part of the observation’s meaning. Align the valuation convention before interpreting small differences in recovery dates as an economic discovery.
The episode that has not recovered is still evidence
Suppose the observed completed episodes last 3, 5 and 8 sessions. Their average duration is about 5.33 sessions. A fourth episode is still underwater after 30 sessions when the dataset ends. Reporting only the three completed episodes produces an appealing average while excluding the most important unresolved wait. Reporting the fourth as a completed 30-session recovery is also false: no recovery has been observed.
The correct elementary description is that the fourth duration is at least 30 sessions so far, with recovery unresolved. In statistical language, the endpoint is right censored. The general issue is well documented in time-to-event analysis: an observation may end before the event being studied occurs. SAS introduction to survival analysis. That vocabulary helps describe missing timing information; it does not make portfolio episodes independent or suitable for every survival model.
Even without fitting a model, you can calculate a lower bound for the mean of these four episode durations if each eventually recovers. Replacing the unresolved duration by its current lower bound gives 46 divided by four, or 11.5 sessions. The eventual mean cannot be smaller under that assumption. It could be much larger, and the episode may never recover within the lifetime of the strategy or account being considered.
An unfinished drawdown is not a zero, a missing nuisance or a completed recovery. Keep a status field next to its age. If several strategies are compared, show how many unresolved episodes each contributes and the observation horizon available for them. A recently launched strategy has had less time to demonstrate a long unresolved wait, which can make a naive historical ranking unfairly favorable.
The ending date of a backtest is therefore part of the result. Extending the same unchanged strategy for another year can lengthen the current drawdown even if maximum depth barely moves. That is additional temporal evidence. It should not be hidden by restarting the index at a convenient new date or renaming the strategy without preserving its prior history.
Flat peaks and tiny new highs need a policy
A portfolio can touch its previous high repeatedly without moving meaningfully beyond it. Under our equality-ends convention, levels of 100, 99, 100, 99 and 100 contain two short completed episodes. Under a strict-new-high convention, the first episode may remain open until the index exceeds 100. Both definitions can be implemented consistently, but they describe different notions of recovery.
Floating-point representation adds another complication. A computed level of 99.999999999 may be economically indistinguishable from 100 at the stated precision, yet a strict numerical comparison treats it as below the peak. Conversely, a broad tolerance can erase a real small loss. Choose a tolerance related to the representation and reporting precision, document it, and test values just inside and outside the boundary.
The tolerance must not become a performance parameter. If the researcher repeatedly increases it until a long drawdown disappears, the definition is being tuned to the desired conclusion. A sensible audit stores both raw values and classification results. This allows someone else to distinguish a numerical stability choice from an economic decision about what counts as recovery.
Preserve the exact recovery rule in the report. For example: the first daily marked observation at or above the prior peak, after a documented rounding convention. Then state whether a flat run at the high resets the starting peak to its first or last observation. In this article, an underwater episode begins relative to the most recent high observation before the decline, which avoids counting a long flat plateau as part of the subsequent loss.
That last convention matters for a rarely traded strategy. If an index stays at 100 for fifty sessions, then falls and recovers five sessions later, measuring from the first point on the plateau produces a 55-session wait. Measuring from the last high before the decline produces five. Neither should be chosen opportunistically; the reader needs to know whether the clock measures time since first reaching a wealth level or the duration of a specific excursion below it.
A deposit can manufacture a new peak
Suppose raw equity falls from USD 10,000 to USD 9,000. The owner deposits USD 2,000, so raw equity becomes USD 11,000. A naive peak detector marks a new high and closes the drawdown. The trading process has not recovered its loss. The account merely received outside resources. This is why the series chosen at the start must match the question being asked.
For a simple no-fee example, represent performance with units. Begin with 100 units at a value of 100 each. After the loss, each unit is worth 90. A deposit buys new units at the current unit value, rather than raising the value of existing units. Raw account equity increases, but the performance index remains at 90 and still needs an 11.11-percent gain to return to 100. The funding and performance histories remain separate and reconcilable.
GIPS guidance discusses time-weighted returns and neutralizing external cash-flow effects in performance measurement. GIPS handbook on return calculation. That is background for distinguishing capital movements from returns, not a claim of GIPS compliance by this article, the website or a hypothetical robot portfolio.
Withdrawals create the reverse distortion. Removing capital can leave raw equity permanently below an old dollar peak despite positive subsequent investment performance. A duration statistic based on that raw peak then measures the combined effect of trading and the withdrawal policy. That may be relevant to a specific cash-resource question, but it should not be labeled simply as strategy recovery time.
Use a performance index for performance recovery and actual equity for funding capacity. Both views can be valuable. A flow-adjusted index does not tell you how much money is available to meet collateral demands, while raw equity does not isolate the trading rule’s return. The companion guide on drawdowns, withdrawals and recovery develops the arithmetic of that distinction.
Open positions and costs can delay recovery
A realized-balance curve only changes when results are booked. An equity curve also reflects positions still open at each valuation. Suppose a robot has realized USD 500 of gains while an open position carries USD 800 of loss. A balance view can show a new high even though the marked account remains below its previous peak. The resulting duration is shorter because the measurement excludes information, not because the economic loss ended.
Transaction costs can change the recovery date without altering the broad shape of a chart. Imagine a gross index first reaches its prior peak on session ten, while accumulated charges leave the net index slightly below. The net index may recover on session fourteen or remain underwater at the sample end. Reporting gross duration next to net return mixes two different paths and can make a weak recovery look complete.
Financing during a quiet period deserves similar treatment. A strategy may hold a position that moves little while financing accrues. If charges are only booked monthly, a daily series can appear flatter than the economic accrual would suggest. Decide whether the research index includes accrued or only posted charges, and explain the consequences for peaks. The choice should reflect available records and the intended measurement, not the shortest resulting wait.
The recovery date inherits every valuation assumption. This includes the side of the quote used for liquidation marks, conversion to account currency, treatment of dividends or other income where applicable, and timing of costs. A report that provides a duration to the nearest minute while leaving those assumptions unstated is offering precision without enough definition.
For comparing supplied systems, reconstruct the same net marked convention for all candidates where data permit. If one file supports minute-level equity and another only completed trades, disclose that limitation rather than placing their durations in a single unqualified league table. Different observation quality can dominate the apparent ranking.
Time below a high is not the same as the longest episode
The maximum duration focuses on the longest excursion. Another useful descriptive quantity is the fraction of observed time spent below the running high. A portfolio with one long episode and many new highs can have a different underwater fraction from a portfolio with frequent short episodes. Neither summary replaces the dated episode table.
Consider two invented twenty-session records after initialization. Portfolio C has one five-session underwater block and is at a high for the other fifteen observations: its observation-based underwater fraction is twenty-five percent. Portfolio D has five separate two-session underwater blocks and is at a high for the other ten: its fraction is fifty percent, even though its longest block is shorter. The metric captures frequency and occupancy, while the maximum captures an extreme interval.
With irregular observations, row fractions can mislead. Ten observations during a busy minute should not outweigh one observation representing a quiet day if the question is calendar occupancy. Weight intervals by elapsed time under a stated convention. If a data gap leaves the state unknown, do not automatically assign the entire gap to the last observed classification without explaining that assumption.
A two-dimensional picture helps: place completed episodes by depth and duration, and mark unresolved ones differently. A shallow but long episode and a deep short episode occupy different regions. The scatter does not establish a universal acceptable region; it shows the forms the observed path took and helps choose which episodes deserve closer investigation.
Avoid collapsing every discomfort into one score. Multiplying depth by duration can be a deliberate descriptive index, but it introduces a trade-off that may not match the user’s actual constraints. A prolonged two-percent decline and a sudden twenty-percent loss are not interchangeable merely because an arbitrary product happens to match. Keep the original quantities visible before experimenting with composite measures.
A portfolio’s recovery is not the average of its robots
Two robots can recover their individual peaks on different dates while their combined portfolio recovers earlier or later than either simple average would suggest. Portfolio equity depends on weights, shared capital, concurrent positions and the chronology of gains. Its running peak must be calculated from the combined path, not assembled by averaging each component’s drawdown duration.
Suppose robot A loses while B gains, then their roles reverse. With fixed weights and genuinely offsetting net returns, the combined path may avoid the individual declines. If both lose together and recover at different times, the combined portfolio may wait until enough of the later recovery arrives. The result depends on the amounts, not just on a correlation coefficient or the number of components.
Rebalancing introduces another rule. A portfolio that periodically restores equal weights follows a different path from one that lets exposures drift. Adding capital to a losing component can change recovery timing, but it also changes the allocation policy being tested. Do not compare the durations as though the only difference were the list of robot names.
Calculate the portfolio path first; measure its drawdowns second. This order preserves the accounting identity between component results and the combined account. It also exposes constraints such as rejected trades or a shared margin limit that can prevent every standalone strategy from operating at its isolated size.
The guide on grouping strategies by behavior explains why different-looking rules can share the same economic dependence. Duration adds another diagnostic: do their underwater periods overlap, and which events end them? That question is more informative than assuming that a larger collection of files automatically creates shorter waiting times.
Historical waiting times cannot set a recovery deadline
After measuring several completed episodes, a reader may ask when the current one should finish. The honest answer is that the historical durations do not supply a deadline. The future may contain a longer episode, a different market environment or a strategy whose previous mechanism no longer applies. An observed maximum is a sample property, not a contractual limit.
Even an estimated distribution requires assumptions. Episodes from one strategy may share market regimes, implementation choices and overlapping economic causes. They are not automatically independent draws. Selecting a strategy because its completed recoveries were fast creates additional selection bias. A more sophisticated statistical model does not erase the consequences of choosing the sample after seeing favorable outcomes.
This does not make duration useless for planning. It means planning should distinguish a descriptive reference from an operating decision. A research review can be scheduled when a process deviates from documented expectations, while the response remains contingent on evidence about data, execution and the original hypothesis. A calendar threshold should not silently become a promise that losses must reverse soon.
One particularly dangerous inference is that a long wait makes recovery due. Time already spent underwater does not create an obligation for the market to return to the previous account peak. That peak is part of the account’s history, not an economically privileged price level recognized by the market. Elapsed disappointment is not a new source of expected return.
A useful review instead asks what remains consistent with the original specification, what observations are new, and which explanations can be checked. Perhaps the strategy is behaving as specified but experiencing an unfavorable sequence. Perhaps costs changed. Perhaps the data feed is incomplete. Those alternatives require different investigations, and duration alone cannot decide between them.
There is a further distinction between a dataset ending on a scheduled date and a strategy being discontinued because its losses became unacceptable. In the first case, observation may stop for an administrative reason. In the second, the stopping decision is related to the path being measured. Treating both endpoints as interchangeable censored observations can distort an attempted statistical comparison. Preserve the reason for the endpoint, even if the basic descriptive table simply marks both episodes unresolved.
A retired strategy does not acquire a hypothetical recovery date from the next rise in the instrument it used to trade. Its rules might not have held the relevant position, and its capital allocation may no longer exist. Continuing the frozen rules in a clearly identified research simulation could produce a separate counterfactual path, but that path must not be substituted for an observed account history. Actual continuation and simulated continuation are different evidence.
This matters when reviewing a catalog that retains only active strategies. Failed or discontinued systems may disappear from the available sample, making the remaining recovery histories look unusually reassuring. Keep an inventory of which systems entered the review, which later stopped and why. A transparent denominator makes the duration analysis more informative than a polished chart containing only the survivors.
Make the episode table reproducible
For each episode, keep an identifier, peak timestamp and value, first underwater timestamp, trough timestamp and value, recovery timestamp if observed, current endpoint, depth, elapsed duration and status. Include the valuation frequency, calendar, equality rule and cash-flow convention in the report metadata. These fields are enough to reproduce the basic descriptive calculations without guessing what a charting package meant.
Test a few deliberately simple paths before using a long history. A continuously rising index should have no underwater episode under the stated convention. A fall followed by exact recovery should close where equality is allowed. A final unresolved decline should remain open. A flat plateau before a decline should use the documented peak boundary. These examples test definitions; they do not prove future profitability.
An AI assistant can help explain and check such a table. Ask it to reconstruct the seven-observation path by hand, identify the four underwater closes and explain why the elapsed episode contains five intervals. Then ask how the answer changes under a strict-new-high rule. A useful answer should expose the convention change instead of presenting one unexplained number as the only possible truth.
Keep the request bounded to analysis of supplied records. Generated calculations need inspection, especially around missing dates, external flows and open positions. The TradeAndRoll demo provides rules, source code and market CSVs for ten Forex systems that can serve as research material. Duration is one of the questions to bring to that examination: not merely how far a path fell, but when the loss began, whether recovery was actually observed, and what the available record cannot yet tell you.



