How to define a Retracement Bar

Forums ProRealTime English forum ProBuilder support How to define a Retracement Bar

  • This topic has 5 replies, 2 voices, and was last updated 2 years ago by avatarMary.
Viewing 6 posts - 1 through 6 (of 6 total)
  • #188583

    Hello,

    I want to place an indicator arrow on a candle bar that has retraced down 45 % from its high, so the wick is at least 45% down from the candle top to the body, how do I define it in Prorealtime?  Same goes for retracement from low of candle, wick retraces at least 45% up from low of candle to body.

    I made this code below but its not correct because its giving me Close and not Retracement of actual wick like I want. Can someone  please help. Thank you.

    IF close <= low + Range * 0.45 THEN
    DRAWARROWDOWN (barindex[1],HIGH [1])coloured(255,10,10)
    elsif close >= low + Range *0.45 THEN
    DRAWARROWUP(barindex[1],low[1])coloured(10,255,10)
    endif
    RETURN

     

     

    #188584

    This should do (not tested):

     

    #188585

    Hi Robert,

    Thank you! Got it working! Thank you very much!

     

     

    #188586

    Hi Robert, after testing this code I find that it is incorrect somehow. If you look at my attached pic below the wicks are not retraced at least 45% of the range as you can see in the pic where the indicators are marked, somehow the code is not picking it up. Any way to adjust it please? Thank you.

    UpperWick = high – max(open, close)
    LowerWick = min(open,close) – low
    UpperRetracement = (UpperWick >= (range * 0.45))
    LowerRetracement = (LowerWick >= (range * 0.45))
    IF UpperRetracement THEN
    DRAWARROWDOWN (barindex[1],HIGH [1])coloured(255,10,10)
    elsif LowerRetracement THEN
    DRAWARROWUP(barindex[1],low[1])coloured(10,255,10)
    endif
    RETURN

    #188595

    It sounds correct.

    Arrows are plotted on the prior candlestick.

    Remove [1]  from the plotting instructions.

     

    #188629

    Thank you Robert, its working now!

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