Set stop loss to an indicator.

Forums ProRealTime English forum ProOrder support Set stop loss to an indicator.

Viewing 4 posts - 1 through 4 (of 4 total)
  • #168541

    Hi.
    I try to adjust my stoploss to my second closest supertrend to the price. But I can’t.
    Does anyone have an idea?
    Thank you

     

    #168545

    I suggest computing the middle of their range like that, for line 54:

     

    1 user thanked author for this post.
    #168547

    There’s a major issue, TRADEPRICE is not known when BUY is executed, until the next candle.

    Due to this it will retain the exit price of the prior trade or 0 the very first time making the stop loss negative.

    To overcome this I’d change line 54 using the current price and saving the ST value for a later use:

    then I would append these lines at the end, for the next candle:

    This will grant you an initial stop loss, making it more accurate next candle.

    1 user thanked author for this post.
    #169201

    Thank you Roberto.

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

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