BREAKOUT / BREAKDOWN FROM A RANGE

Forums ProRealTime English forum ProOrder support BREAKOUT / BREAKDOWN FROM A RANGE

Viewing 5 posts - 1 through 5 (of 5 total)
  • #4670

    Hello Everyone

    May I please ask for any ideas or code snippets to get me started or even a full ‘Auto System’ to perform the following …

     

    Breakout or Breakdown from a Range.

    The sort of range I am thinking of are usually tightish / narrowish and often seen as consolidation after a strong rise up or down.

    Please refer me to any existing systems on this website or anywhere that you feel may do the job?

    Hope above makes sense, just say if not.

    Many Thanks

    GraHal

     

    #4674

    Hello GraHal,

    This is not very difficult to code this kind of strategy, but how you would define a range after a strong rise up or down? A range is easy to spot with charts in front of human eyes, but not so with a mathematical process and that’s where the problem is. I would say that bollinger bandwidth may do the job for what you want to do here, take a look on it and maybe try to build a strategy around it.

    #4676

    Hi GraHal,

    As Nicolas says, what are the exact specifications for this range? Start by defining these as simple text and then we could help you turn it into code. Something like (on a day chart):

    • Look two weeks back, what is the highest high that gets hit at least two times with at least four days space in between? Define that price level as X.
    • Look two days back, is it above X? If yes, look one days back, is it above X? If yes, look today, is it still above X? If yes, upward breakout confirmed, do something.
    • If no to any of the above, breakout not confirmed, go back to first point, do nothing.

    Something like that…

    #4834

    Hi Guys and thank you both for your suggestions.

    As an example, I was thinking …

    1.  If a run up / run down of N points followed by a trading in a (narrow) range of N1 points over  N2 bars (often a near horizontal channel can be seen) then if …

    Breakout above highest high over N2 bars – go Long.

    Breakdown below lowest low over N2 bars then SellShort.

    I would use PositionPerf = – N3 to get me out of the Trade.

    I often trade manually as above and it more often than not gives me profit if I am nimble enough to get out before it retraces too much!

    I would use backtest to optimise the value of N, N1, N2 and N3.

    Many Thanks

    GraHal

     

    #63246

    Morning,  I have been playing with this again and have simplified the code  but I only want orders to be placed within 10% of the break of the range.  Right now new orders get placed as soon as I take profit,  any ideas how to make sure that does not happen?  this is the current code

     

    1 user thanked author for this post.
Viewing 5 posts - 1 through 5 (of 5 total)

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