fxDreema

    • Register
    • Login
    • Search
    • Back to the main page
    • Categories
    • Recent
    • Tags
    • Popular
    • Search
    1. Home
    2. roar
    3. Posts
    • Profile
    • Following 0
    • Followers 184
    • Topics 35
    • Posts 2406
    • Best 422
    • Controversial 6
    • Groups 0

    Posts made by roar

    • When to stop OnInit()

      When viewing the generated code, the OnInit() function always contains the code shown below.

      What is the purpose of it? It seems the code stops the initializing process if the init reason is a change of symbol or change of timeframe.
      Well that seems appropriate for most cases, but why the else statement? Now the init is stopped in any case, right?

      The problem: Lets say a project contains some graphical objects on the OnInit() tab, and some boolean constant input determines if those objects should be drawn or not.
      If the user changes this boolean while the EA is running, the changes will not take effect because the OnInit() is stopped before those blocks are executed.

      I often delete that else statement manually to make those objects inputs work properly, but I'd rather have this code changed for good.

      Example: https://fxdreema.com/shared/pd9JF900c

      9cd9e8ca-f048-4b3b-aec4-1e46b3eee0da-image.png

      posted in Bug Reports
      roar
      roar
    • RE: Close the Running trade for the opposite signal

      @Harjhady what have you tried this far?

      posted in General Discussions
      roar
      roar
    • RE: Can I close most recent position that will factor in original balance and (negative equity) from open positions in drawdown?? (Round 3)

      @fxbam yes, there is way. First step is the average open price calculation. This is how to do that:
      https://fxdreema.com/shared/HvAUS7jNd

      posted in Questions & Answers
      roar
      roar
    • RE: Here, take this profitable ea

      @seb-0 well, I do optimize some times, but much less than before.

      To my experience, with optimization you can make any EA look super good. Whats the point... the performance will not repeat in live trading.

      So, if the EA doesnt look promising with random inputs backtest, I dont usually bother to force it look good with optimization.

      Its 98% about the strategy itself, 2% about the input values.

      posted in Tutorials by Users
      roar
      roar
    • RE: Can I close most recent position that will factor in original balance and (negative equity) from open positions in drawdown?? (Round 3)

      Ok, so the math exam question is this: we have multiple positions with varying sizes, with varying TP levels. Calculate what the total profit is when price moves to point x.

      This is an average open price calculation, with the assumption that all trades close at the same point (=some trades dont close before others). To calculate average open price, weight each open price with the trades proportion of total lot size, then sum up the weighted open prices.

      When we handle this calculation, its easy to insert the final trade into the equation.

      posted in Questions & Answers
      roar
      roar
    • RE: Here, take this profitable ea

      @seb-0 I dont remember, lol.

      When I optimize, I use recovery factor as the parameter. Nowadays I dont optimize at all.

      posted in Tutorials by Users
      roar
      roar
    • RE: Increase Lot Size and Close all? (Round 2)

      Here is a function to calculate lot_size when target profit is 567 $ and 123 pips.
      https://fxdreema.com/shared/WYkYDtbee

      Now you will need to put your own target profit amounts to the formula.
      image.png

      posted in Questions & Answers
      roar
      roar
    • RE: Increase Lot Size and Close all? (Round 2)

      So, when calculating the lot size, we know the TP pips and we know how much $$$ the trade will yield. There is actually some functions to make this calculation, let me make an example...

      posted in Questions & Answers
      roar
      roar
    • RE: Increase Lot Size and Close all? (Round 2)

      @fxbam so the closing part is actually done already, but we need to calculate the lot size, given current drawdown and TP level? The TP level is same for all trades?

      posted in Questions & Answers
      roar
      roar
    • RE: Increase Lot Size and Close all? (Round 2)

      @fxbam ok, so maybe do this:

      1. Calculate the total profit of all running trades (profit can be positive or negative)
      2. Condition: total profit > 1.01 * Balance
      3. Close all trades

      Do you think this would work? Does the balance stay same during the process, or do you close some trades early?

      posted in Questions & Answers
      roar
      roar
    • RE: Increase Lot Size and Close all? (Round 2)

      So your goal is to close all trades when the overall profit (or "net profit") is +1% of balance?

      posted in Questions & Answers
      roar
      roar
    • RE: Any luck on extending Take Profit?

      @GTOAT777 you should make an example that is actually testable.

      Here, check this one. TP is modified successfully.
      https://fxdreema.com/shared/Uth3r2G5b

      b50761c1-9e27-46b6-a4d7-2cc6cbd46645-image.png

      posted in Questions & Answers
      roar
      roar
    • RE: Any luck on extending Take Profit?

      @GTOAT777 do you have some example project?

      posted in Questions & Answers
      roar
      roar
    • RE: Any luck on extending Take Profit?

      @GTOAT777 me too, lol
      eebb0cc9-541a-4d07-a825-eae068fbf941-image.png

      posted in Questions & Answers
      roar
      roar
    • RE: Any luck on extending Take Profit?

      Sure, just select the trade and then modify stops.

      posted in Questions & Answers
      roar
      roar
    • RE: Close On Equity*

      @Morpheus_0 if you want to close at 10% drawdown, the condition is this: equity < 0.90*balance

      So you need 90% in the adjust field

      posted in Questions & Answers
      roar
      roar
    • RE: Close On Equity*

      @Morpheus_0 do you want to close at 90% drawdown or 10% drawdown?

      posted in Questions & Answers
      roar
      roar
    • RE: how to conver indicator ex.4 to mql.4

      @AKIM-0 can't be done.

      posted in Questions & Answers
      roar
      roar
    • RE: EA uses wrong lotsize

      To me, there is lots of weird stuff happening in your project. Here's some of them:

      • "Once per position" block needs a parent block that seeks the position in question. So the loop "For each position" must be on top there.
      • Formula #42 needs the result of formula #15, so those blocks should be linked together, not parallel (although your block IDs luckily avoid problems there)
      • You are using candle close ID 3 as the stop-loss level, without checking that this level is below/above for buy/sell trades
      • You are using a pip value as trade volume, and furthermore, a pip value converted into a string. Trade size should be a number.
      posted in Questions & Answers
      roar
      roar
    • 1
    • 2
    • 17
    • 18
    • 19
    • 20
    • 21
    • 120
    • 121
    • 19 / 121