fxDreema

    • Register
    • Login
    • Search
    • Back to the main page
    • Categories
    • Recent
    • Tags
    • Popular
    • Search
    1. Home
    2. TXZZ
    3. Posts
    T
    • Profile
    • Following 2
    • Followers 1
    • Topics 9
    • Posts 27
    • Best 0
    • Controversial 0
    • Groups 0

    Posts made by TXZZ

    • Block"for each trade"Affects backtesting speed

      I wrote a Martingale Expert Advisor (EA), but the backtesting speed becomes increasingly slow as the number of historical orders increases. I tried using Grok to solve the problem, and its judgment is the same as mine, but its fix always results in a compilation error. I hope Fxdreema can fix this so that I don't have to modify every Martingale EA.

      The problem you encountered is very typical: the Expert Advisor (EA) generated by fxDreema slows down considerably during backtesting as the number of historical orders increases, eventually even freezing.

      The core reason, as you identified, is that Blocks 11 and 15 (i.e., MDL_LoopOncePer) iterate through the entire historical order history (OrdersHistoryTotal()) on every tick, using OrderSelect(i, SELECT_BY_POS, MODE_HISTORY) + OrderOpenTime() >= TimeAtStart() to determine if an order is from the current startup.

      As the backtesting period lengthens, with tens of thousands of historical orders, these two blocks perform a full table scan every tick, leading to a catastrophic performance drop.

      The best solution (minimum changes + complete resolution) is simply to change the implementation of the MDL_LoopOncePer class from "iterating through historical orders" to "using a static array to record the parent tickets that have been processed."

      Modify the following location: Locate the class MLD_LoopOncePer<bool> (around lines 600-650 of the code).
      @fxDreema

      posted in Bug Reports
      T
      TXZZ
    • RE: Backtesting is getting slower and slower

      @l-andorrà Thank you. This is such sad news.

      posted in Questions & Answers
      T
      TXZZ
    • RE: Backtesting is getting slower and slower

      https://fxdreema.com/shared/CtpS6sUWd
      For example, in this example, it was very fast at the beginning, but the chart time slowed down after a few hours. After more than ten hours, it was as slow as a snail. I feel that it has something to do with the number of trade, but I set not more than 1 trade in the "for each trade" block. Logically, this situation should not occur. I really don't understand it.

      posted in Questions & Answers
      T
      TXZZ
    • Backtesting is getting slower and slower

      Why does the backtesting speed become slower and slower for strategies using the "for each trade" module?

      posted in Questions & Answers
      T
      TXZZ
    • Hope to add “Stop Limit Order”

      MT5 has a third type of pending order, it is called "Stop Limit Order", but fxdreema does not have this function now. I hope it can be added. Thank you.
      @fxDreema

      posted in Questions & Answers
      T
      TXZZ
    • RE: A BUG ABOUT BETTING:CUSTOM SEQUENCE / LOOP

      @l-andorrà Normally it should be 0.01, 0.02, 0.03, 0.04 ...... to close the position and then continue 0.01, 0.02, 0.03 ...... to close the position. But there is a bug so it will happen like above.

      posted in Bug Reports
      T
      TXZZ
    • RE: A BUG ABOUT BETTING:CUSTOM SEQUENCE / LOOP

      @TXZZ Backtesting will look like this: 0.01, 0.02, 0.03 ...... closed; then 0.01, 0.03, 0.04 ...... closed; then 0.01, 0.04, 0.05... ...

      posted in Bug Reports
      T
      TXZZ
    • RE: A BUG ABOUT BETTING:CUSTOM SEQUENCE / LOOP

      @l-andorrà https://fxdreema.com/shared/rkUXHYUde

      posted in Bug Reports
      T
      TXZZ
    • RE: A BUG ABOUT BETTING:CUSTOM SEQUENCE / LOOP

      @TXZZ MT4 Had the same problem.

      posted in Bug Reports
      T
      TXZZ
    • RE: A BUG ABOUT BETTING:CUSTOM SEQUENCE / LOOP

      My friend and I are also experiencing problems with lots not resetting, we think there may be a problem with the MT5 block, could the author take the time to check it out.
      @fxDreema

      posted in Bug Reports
      T
      TXZZ
    • RE: How to use ZigZag [advanced]

      @miro1360 said in How to use ZigZag [advanced]:

      hi, you must do another system for crazy MQL5 with few changes in logic, something like this:
      (import project to see details in externs-inputs) https://fxdreema.com/shared/jmgcWOcIc

      0_1518483767203_b9d7a5ad-cfe7-4c64-b48b-6363e56a111d-image.png

      0_1518483665267_1bd9aece-7ca9-4b5d-8820-c03e6ae50728-image.png

      Using this method, it works fine most of the time, but when I was testing it, I noticed that it would occasionally throw an error. For example, when I tested EURUSD_M15 in ICMarkets with the default parameters, I got an error at 17:15 on 2023.01.02 and a few minutes after that, the ZZ indicator on the chart was going down, but the result of this algorithm was showing up, so I changed the zz_ID_interval from 200 to 49 and it showed up correctly! . What is the reason for this, please? Can it be solved? I want it to be correct all the time.

      posted in Tutorials by Users
      T
      TXZZ
    • RE: How do I get the maximum float value

      @seb-0
      @Pheaktra-Capo
      Thank you very much

      posted in Questions & Answers
      T
      TXZZ
    • RE: How do I get the maximum float value

      @seb-0 Floating loss value, the value of open positions

      posted in Questions & Answers
      T
      TXZZ
    • How do I get the maximum float value

      How do I get the maximum float value for a set of orders for the time period from opening to now and use the value as a variable for other modules?

      posted in Questions & Answers
      T
      TXZZ
    • RE: Why does the loop in this example not work?

      @ambrogio Wow, finally solved, thank you very much for your guidance.

      posted in Questions & Answers
      T
      TXZZ
    • RE: Why does the loop in this example not work?

      @l-andorrà Thank you very much

      posted in Questions & Answers
      T
      TXZZ
    • RE: We need to have an in-built News Filter...It is high time we have this MT4 and MT5

      I think it's a great idea, one feature can't be useful for everyone, like the current blocks, more than half of them I don't use most of the time, but it doesn't mean they don't have a value, on the contrary, it's the extensibility and versatility of FXDREEMA that makes it stand out among other editors, that's the biggest advantage of FXDREEMA, so it's necessary to continue to expand this advantage. necessary. As long as a certain feature block is needed by a significant part of the population, it should be added.

      posted in General Discussions
      T
      TXZZ
    • Why does the loop in this example not work?

      https://fxdreema.com/shared/5ZY3FQfH
      I want to calculate the total size of the past N candles: the size of each candle is added together.
      Why does the loop in this example not work?

      posted in Questions & Answers
      T
      TXZZ
    • RE: recovery after loss

      同样的问题,我也想这么干,可惜这里没有解决方法

      posted in Questions & Answers
      T
      TXZZ
    • RE: How to edit the trade only in the specified hour?

      @l-andorrà
      For example, the numbers on the right are 10, 15, 21. Then it means that transactions are only allowed between 10:00-10:59, 15:00-15:59, and 21:00-21:59.

      posted in Questions & Answers
      T
      TXZZ
    • 1
    • 2
    • 1 / 2