Skip to content
All library documents

Detrending Returns to Evaluate Trading Rule Performance

Article Quant Q&A · Author: Daniel Cooke

Summary

The document clarifies how a trading rule can earn positive returns on detrended market data even when the series’ average daily return has been set to zero. Detrending removes the overall drift while leaving shorter-term fluctuations; a rule may still profit if its long and short positions align with those movements. Random rules should average to zero adjusted return, though individual rules can perform above or below that level.

It describes two ways to assess performance: calculate profit and loss directly on a detrended series, or adjust actual results by subtracting the return attributable to the market’s drift and the strategy’s long and short exposure. The example explains the adjustment using a rising index and a strategy with unequal time spent long and short, and corrects an arithmetic slip in the initial calculation. The discussion is an informal explanation rather than a validation method; it does not address transaction costs, statistical significance, or how detrending choices affect conclusions.

Key ideas

  • Removing a series’ drift does not eliminate its shorter-term price movements.
  • A trading rule can have positive adjusted returns if it selects favorable moves after detrending.
  • Random rules are expected to average zero detrended return, while individual results can vary.
  • Performance can be evaluated directly on detrended prices or by adjusting actual profit and loss for drift exposure.
  • The example does not establish statistical significance or account for trading costs.

Tags

Full text
# Detrending market data to calculate expected return (ER)


# Detrending market data to calculate expected return (ER)












I'm a complete newbie so please be kind.

I'm reading

> Evidence-Based Technical Analysis: Applying the Scientific Method and Statistical Inference to Trading Signals by David Aronson

And I'm struggling to understand the following excerpt:

> ER = [p (long) × avg. daily return] − [p (short) × avg. daily return] For example, if the position biases were 60 percent long and 40 percent short, the expected return is zero. 0 = [0.60) × 0] − [0.40 × 0] Position Bias: 60 percent long, 40 percent short If, on the other hand, a rule does have predictive power, its expected return on detrended data will be greater than zero. This positive return reflects the fact that the rule’s long and short positions are intelligent rather than random.

I fail to see how its possible for this equation to ever produce a result greater than zero if the detrended market data mandates the avg. daily return to be 0.

## Answer by nbbo2 (score 2)

https://quant.stackexchange.com/a/63145

The point is simply that a trading system selects some days to be long and some days to be short, and if you are lucky or good it selects days that will have a positive return even after removing the drift or upward bias during the overall period. If you try trading rules at random on average they will have zero detrended ret (you are right about this), but some will have pos and some negative detrended return.

Suppose S&P starts the year 2020 at 2500 and ends the year at 3000. That is a 500 point trend. The detrended S&P starts at 2500 and also ends at 2500, but with a lot of waves up and down. On this detrended series you can still make P&L if you "catch the waves" correctly.

`Ah. I see, I think its maybe the wording that has confused me. So in other words when he says "its expected return on detrended data" he is referring to the actual observed return on detrended data? not the ER formula itself.`

Yes, you got it. There are 2 ways to do it. Compute P&L on detrended data (easy), or use the formula above, which can be used to adjust the actual P&L per day to detrended P&L by subtracting ER. For example there are 250 trading days in the period so avg. daily return=500/250 =2. Suppose a strategy was long for 100 days and short for 2 days. Then ER= (100/250)*2-(2/250)*1= 0.792 per day. If your strategy had actual P&L of more than this per day it would have positive adjusted P&L. Makes sense? (I don't have Aronson's book any more but this what I remember).

Slight errata: ER = (100/250)*2 - (2/250)*2 = 0.784. The average daily change (ADC in formula on page 26 of book) should be the same for both the probability of a long and the probability of a short.

## Answer by John (score 0)

https://quant.stackexchange.com/a/55467

by definition once you remove the trend and other volatility clustering patterns, you are left with white noise, without correlation whatsoever

Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)

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