Lag in orders

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

    Hello,

    I see in a backtest that orders are placed at the next bar open. Now I have a strategy based on daily condition, but I want to place an order during the next day when the conditons are met on daily basis the previous day and the high of the current day is higher than the previous day. I do not want to wait till the next day open but I want to buy as soon as possible. I tried to work with different timeframes but get errors. I think it is easy to answer for you as experts?

    Thanks for your replies in advance

     

    #144529

    With MTF code you can indeed test a daily timeframe condition each 1 sec. Please post your code so we can point you how to make it.

    #144533

    Hi Nicolas,

    Thanks for you quick repy and your help.

     

     

     

     

    SET TARGET %PROFIT x
    set stop %loss y

    #144537

    Seems to be only a part of the full strategy? Anyway, here is how it should be coded:

    You can launch it in any inferior timeframe than the daily one. Code will be read one time each bar, 1-minute would be fine.

    #144541

    Thank You!

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