%Stop @ -2%

Viewing 7 posts - 1 through 7 (of 7 total)
  • #98379

    Hi all !

    I’d like to create a %Stop @ -2% (like today for instance) but from the “Dopen”.

    Why? Cause most of the time, the instrument bounce back a bit from the specific % amount of distribution…

    It should be something like the following but I have trouble replacing the (0) by the correct value…

    Any help please ?

    Thank you 😉

     

    #98382

    Replace line 1 with:

     

    1 user thanked author for this post.
    #98401

    Thank you Robertogozzi !

    It works fine until 0.99% but then it goes blank from 1.0, 1.1 onwards…

    #98402

    From 1.0  onwards C1 will be false and there will be no exit due to stop loss.

    I think you also added some target profit.

    I am not sure I could understand what you really meant.

    1 user thanked author for this post.
    #98406

    Hi Robertogozzi,

    Thank you for your time !

    Your are right, it should mostly have a second “%TP” from the “Dopen” this time !

    Not a %stop cause it’s a short position :/ ! My mistake…

    So the strategy should then have “technically” two %Target Profit with and IF somewhere in the middle I suppose…like and OCO order.

    • (1) SET TARGET %PROFIT 1 like the code
    • AND
    • (2) If the TP (1) is not triggered then (2) … c1 = close <= (DOpen(0) * 2%)

    Is it clearer Roberto?

    Good night and thank you for your help.

     

    #98407

    In your code this is a 20% gain on a short:

    2% would be 0.98 as Robertogozzi already said.

    This condition whether 2% or 20% will never be hit if you also have SET TARGET %PROFIT 1 in your code – which you do have.

    1 user thanked author for this post.
    #98408

    Ok, now I got it !

    Big thanks Vonasi and Robertogozzi !

    FYI for you, It gives even better results…

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

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