Leveraged Trading – Robert Carver

Forums ProRealTime English forum ProBuilder support Leveraged Trading – Robert Carver

Viewing 6 posts - 1 through 6 (of 6 total)
  • #116319

    Hi All.

    If you’ve not read Leveraged Trading by Robert Carver yet I would commend you to do so. Ex PM at AHL Hedge Fund in London so he knows his onions!

    I’m trying to build a simple breakout indicator that he demonstrates in his book. It’s a rolling max/min indicator based on ‘n’ days (either 10, 20,40,80,160 or 320)

    The formula is as below (for n=10 days)

    n=10

    A= 10 day rolling high

    B = 10 day rolling low

    C = average of A + B

    Scaled price = (Todays price minus – C) / (A-B)

    The output ideally would be the bands over the price (akin to Donchian Channel) and the lower indicator shows range from 1 to -1.

    Example (in Google Docs):

    https://docs.google.com/spreadsheets/d/15A3qW4Nx0n82gKF0BhZt7oq9a09Z4V3z7QLcIo8bkxs/edit#gid=1807469130

    Many thanks in advance!

    #116329

    The output ideally would be the bands over the price (akin to Donchian Channel) and the lower indicator shows range from 1 to -1.

    I’m not sure of what you mean by the above. An image of how the indicator should look would be helpful.

    The following should calculate your scaled price (not tested):

     

    #116435

    Hi Vonasi

    The scaled price would vary between 0.5 and minus 0.5. max and minimum. So I was thinking as well as the breakout channel that the above calculations would draw (max, average and min) over the price chart, the lower indicator panel would show the actual scaled price value ranging between +0.5 and -0.5? Is this possible?

    #116444

    So you are saying that you want three lines on the price chart showing a, b and c?

    I guess that the highest and lowest should not then include the current still forming candle? So if n=10 then it should be checking for the lowest and highest in the previous 10 candles. This way we can see a breakout of the upper and lower lines.

    Does the separate scaled price indicator need to consider the current still forming candle? I guess it would.

    The only way to do what you want is to create two separate indicators. One is applied to the price chart and the other is added as a separate indicator.

     

    #116446

    Here you go? (not tested).

    If you want the lines to include the current candle then just change [1] to [0] after high and low in the code.

     

    #116460

    Super thanks Vonasi. Great help.  I’m just trying to see what this produces in a backtest with a simple MA rule (as Carver suggests). It seems many of the CTA’s use very simple trend following models trying to catch the meat of the trend systematically rather than over-fit a great backtested model that fails to work in reality!

    Carver, Clenow et al, are all using Python with the Pandas package these days for back testing etc. I really need to start learning how to code that!

    Thanks again. Great help.

    Grim

Viewing 6 posts - 1 through 6 (of 6 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login