variation price program

Forums ProRealTime English forum ProOrder support variation price program

Viewing 15 posts - 1 through 15 (of 29 total)
  • #192210

    Hello I would like to write this code if someone can help me I would be very grateful
    I will buy the asset at the opening of each candle if its price changes by 70%. take profit yes +0.5%. stop-loss -0.5
    I will sell the asset at the opening of each candle if its price changes by 70%. Take profit -0.5%. Stop-loss +0.5%.
    Time unit 15min. Thank you for your understanding.

    #192212
    JS

    Hi @Dovakin

    Do you mean a price change of 70% in 15 minutes?

     

    #192246

    no. 10%. sorry.

    #192247
    can you please make me this code for the cac 40. On opening of each candle if the stock takes 1%. Open buy position. Close the position if it takes +1%. Stop loss -0.8% Also on each candle opening if the cac loses 1%. Open sell position. Close position if it loses 1%. Stop-loss +0.8%. time 1h. Thank you for your time.

     

    #192249
    JS

    You can adjust everything yourself:

    1. Number of contracts
    2. % stop loss
    3. % take profit
    4. Tijdframe
    5. Index

     

    #192250

    Thank you very much but I have entered the code but nothing is displayed no matter what period I choose

    #192252
    JS

    Hi @Dovakin

    Did you BackTest the code?

    #192253

    I don’t know if I expressed myself badly but this is exactly what I want
    each candle has an opening i want to take position from that opening. then i want to multiply that opening by 1%. and exit that candle if i am right with a 0.6% gain. if i am wrong i take a 0.3% loss. i am sorry i am a novice.

    #192255
    JS

    At the opening of a candle what kind of position do you want to take (Long or Short) and under what conditions do you want to go Long or Short?

    I don’t understand what you mean by “multiply the opening by 1%”…

    #192265

    For example this candle of March 16, 22 of the ndx 100 at 20:00 the opening is 13738.2.  In the framework of a long position, if the asset gains 1%, I take 13738.2 and multiply by 1%. That gives me 13875.582. If I reach 13875.582 I take a buy position. If from 13875.582 I gain 0.4% I exit my buy position with a gain. In case I reach 13875.582 and I have a drop of 0.4% I exit my buy position with a loss. And I do this for each candle on a time unit of 1 hour.

    In the case of a short position like this 26th of April at 3pm of the ndx 100. The opening is 13477.7. If the asset loses 1%. I take the opening which is 13477.7 which I multiple by 1%. That makes 13342.99. And then I take a sell position. If from 13342.99 I gain 0.4% I exit my sell position with my gain. If on the contrary the price goes up I exit at 0.4% with a loss. And this for each candle on a time unit of 1 hour

    #192271
    JS

    Hi @Dovakin

     

    3 users thanked author for this post.
    #192278

    What timeframe is that?

    #192281

    thank you Mr JS.

    Entry is 13384,015 NOT ONLY 13251,5. BECAUSE I TAKE POSITON WHEN<span class=”Apple-converted-space”>  </span>I HAVE OPEN*1% like here 13251,5*0,01 equal 13251,5+132,52 equal 13384,015.<span class=”Apple-converted-space”>  </span>IF I HAVE 0,4% OF PROFIT I CLOSE MY POSITION LIKE 13384,015*0,4% EQUAL 13384,015+53,55 equal<span class=”Apple-converted-space”>  </span>134737,55 , I close my position with profit. But if I have 13384,015*0,4 equal 13384,015-53,55 equal 13330,47 I close my position with loss.

    #192283
    JS

    @phoentzs

    TF = 1 hour

    #192286

    just one thing if we take this trade from April 25 at 4 p.m. it’s the same for the others.
    Entry is 13384,015 not only 13251,5. Because I take position when I have open*1% like here 13251,5*0,01 equal 13251,5+132,52 equal 13384,015.

    If I have 0,4% of profit I close my position like 13384,015*0,4% EQUAL 13384,015+53,55 equal 134737,55 , I close my position with profit. But if I have 13384,015*0,4 equal 13384,015-53,55 equal 13330,47 I close my position with loss.


     

     

Viewing 15 posts - 1 through 15 (of 29 total)

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