open range strategy code – lot of success

Forums ProRealTime English forum ProOrder support open range strategy code – lot of success

This topic contains 33 replies, has 9 voices, and was last updated by avatar dillongr 1 month ago.

View all attachments
Viewing 15 posts - 1 through 15 (of 34 total)
  • #48596

    Hi,

    I have had a lot of success with an open range break strategy and I am trying to see if I can automate the strategy, but my limited knowledge of coding is proving to be a challenge

    I am trying to define the opening range on the 5 min, for a set period of time.  using the dax as an example:

    • open range is high and low of 5 min candles between 8am and close of the 8:55 five min candle.
    • entry is 2nd  5 min close above /below the range
    • exit is a Fibonacci expansion of, 261.8

    very simple and reliable in my intraday trading on SAF40, Dax, Dow, FTSE and US500.

    Does anyone know how you define the range?

     

    #48614

    Hi dillongr

    try something like this for high (hh) you can also use it as an indicator by “return hh” to see that the time are in right place

     

     

    #48615

    and low (ll)

     

    #48618

    Where is your stop loss for this strategy?

    #48620

    thanks Eric!

    SL is normally at the top or bottom of the range depending if you are long or short.  Price normally comes to test the 50% Fibonacci of the range before continuing on the breakout.  I also use a 15ema to confirm trend direction

    #48621

    If you have a long breakout you take the bottom of the range as SL and for short the top? Sounds funny. I will program this.

    #48622

    Entry condition you write the second close outside the range. Shall this two closes be consecutive?

    And tagte is the 261.8% fibs expansion. So if the range is 100 points wider you have a take profit of 261.8 points above the range top? This is far away!

    #48623

    I coded this here with a profit target at the 161.8% fibo extension (that was already bad enough) and at least for the dax the result was not very promising.

    Here is the code if you want to play with it:

     

    Attachments:
    #48644

    Same code as Despairs but without EMA15 and a time end for buy at 09:16, tested with 1 WF at 60% resulted in fib 1,5 on OMX 30.

    Andy

     

    Attachments:
    1 user thanked author for this post.
    #48651

    Ooops, attached 3 times 🙂

    #48659

    dont forget spread and slippage (sweden30)

    #48660

    Spread was 0,9 should be ok I think, what do you mean with slippage Eric?

    #48661

    Looks really good.

    Backtest with 200k .. 🙂

    #48664

    about slippage on sweden30, i mean if you get a bad fill on market order or stop around the open of cash market

    but run it on demo it may not be a problem after all?

     

     

    #48667

    Andy

    On my computer it looks like this.?

    Strange.

     

    Attachments:
Viewing 15 posts - 1 through 15 (of 34 total)

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