Avoid several trades within 1 candle

Forums ProRealTime English forum ProRealTime platform support Avoid several trades within 1 candle

Viewing 2 posts - 1 through 2 (of 2 total)
  • #244888
    Dear Community,
    in backtesting, my algo opens several positions within1 Candle (DAX – Timeframe 1mn)
    I want to avoid “defparam cumulate orders = false”, because I want open another position if there is an entry conditions later a day, but not within the same candle.
    Maybe, it is only a backtesting problem, I am not sure. Attached, I have simple code to demonstrate my problem.
    Can anybody help me please?
    Thanks in advance and best regards!
    #244917

    As I can read in your code, it’s impossible that more than 1 short trade is entered on the same candle on the 1-minute bar if you are using a 1-minute timeframe, because once the entry conditions are met they won’t be evaluated again until next bar.

    It only may occur if you are using a lower timeframe.

    Please post the code you are using and info about the default timeframe.

     

     

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

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