I have a strange problem. I am running a backtest on a strategy whose signal is based on a spread. Naturally, a spread can go negative or positive. If I try to calculate the log return of a difference between two negative points in the spread it goes undefined.

Is there a standard method of "pushing the spread up"? I thought about a few very naive methods and the only one that made sense was to add a constant value to every element equal to the lowest value the spread goes. By doing this the distance between two successive points is maintained. The only problem is the return is not:

Take two points on a spread -1 and -2 and let's say we add 50 to them when we push the spread above the zero line:

log(1) - log(2) = -0.69314718055994        (1 and 2 made positive here to show the expected value)
log(51) - log(52) = -0.019418085857101808

So this method, while simple, does not work. As you might expect the log-percentage difference between 51 and 52 is significantly smaller than 1 and 2.

Is there a better, more effective way to do this?

  • 1
    $\begingroup$ to calc the log return, use the log relation that log(P2) - log(P1) = the return so there shouldn't be a problem with negative returns. Basically, backout the prices and don't deal with spread. $\endgroup$
    – mark leeds
    Oct 8 '19 at 1:32
  • $\begingroup$ @markleeds Thanks for the reply - am I understanding correctly that if you calculate the log return for each leg the spread return would just be the sum of the log returns of each leg? $\endgroup$
    – CL40
    Oct 8 '19 at 1:37
  • $\begingroup$ It is a (zero investment) portfolio where you are long one thing and short another. The simple return (per dollar long) of the 2 positions would be the sum of the simple returns of the long and the short. To find the log return requires one extra calculation: $r_L=\log(1+r_S)$ $\endgroup$
    – Alex C
    Oct 8 '19 at 12:39
  • $\begingroup$ Cl40: Are you using log returns or arithmetic returns. For small returns, it doesn't matter but, for longer ones, it can. If you're using arithmetic, then you can add them. I'm not clear on what Alex C is saying ( the relation he wrote ) but it's a good idea to listen to what he's saying. I'm listening !!!!! $\endgroup$
    – mark leeds
    Oct 9 '19 at 0:11
  • $\begingroup$ @markleeds I am using log returns, the returns are daily so they are sufficiently small - but Alex C's formula is always helpful to remember. $\endgroup$
    – CL40
    Oct 9 '19 at 1:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.