fxDreema

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

    Best posts made by roar

    • RE: Check Candle 1-5 if Price was higher then MA

      @siggi12345 sure!

      To operate our loop, we need to first create 2 variables. The variables menu opens from the top of blocks list.
      0_1600969360771_59128d43-7e79-4105-b78a-31afac339e16-image.png

      The idea in my loop is to first set some boolean variable ("success" in the example) to TRUE, and then loop through all 5 candles -> if some of them breaks our condition, the variable is set to FALSE.
      After the loop, we can simply check if our variable has stayed TRUE, which would mean that all conditions were ok.
      https://fxdreema.com/shared/6Zmxnuj6c

      Edit: wrong pic

      posted in Questions & Answers
      roar
      roar
    • RE: How to set/check a time stamp or candle ID

      @ikarus_ yeah looks ok, but because of the missing variables, cannot see the variable modifications (in right-side of blocks) which are critical for the logic
      0_1601017232351_606baba9-8148-4f8f-879d-f19b3ae27e4f-image.png

      posted in Questions & Answers
      roar
      roar
    • RE: Check Candle 1-5 if Price was higher then MA

      @siggi12345 yes this is pretty technical stuff, youre smart for learning it so fast!

      Answer to question: "Pass orange first" is my method of organizing the whole algorithm. It first does the loop thing, and later does other things (whatever is connected to yellow output).
      Basically just to make sure the EA doesnt check the loop results before the loop has even done its calculations.

      Oh, didnt know about the casing.. I don't use boolean variables myself, just integers 0 and 1 for true/false, but I thought that would confuse others..

      posted in Questions & Answers
      roar
      roar
    • RE: How to set/check a time stamp or candle ID

      @ikarus_ this block needs to change the variable when the loop finds a suitable candle, otherwise the algo never proceeds to the next stage
      0_1601031610038_e914eee8-4e57-4e43-ac22-818eec0a3c55-image.png

      You dont need to reset the IDs, they dont matter in this EA. I just like to keep them small myself, just a preference.

      posted in Questions & Answers
      roar
      roar
    • RE: How to set/check a time stamp or candle ID

      @ikarus_ said

      I think there is a big learning curve awaiting for me about loops.

      Yes I think its more "advanced" stuff - and the worst part is, this particular loop logic is my own scribble lol

      There is also an official loop block in the builder, it works a bit different. If youre familiar with the coding jargon, my loop here is a while loop, whereas the fxdreema loop block is a for loop.

      posted in Questions & Answers
      roar
      roar
    • RE: How to set/check a time stamp or candle ID

      @ikarus_ Sorry, I confused even myself with the true/false things here.
      Made a fix: the comparator in the second block is ==, not !=.
      0_1601032823174_25678c0e-5194-4005-ad7a-e1b8922f72ce-image.png

      So, the logic is

      • when variable is false, run the loop and try to find a candle setup which makes the variable true
      • when it is true, proceed to next section of the EA.

      Edit: Goddamn now I'm confusing my projects with each other, fixed again.

      posted in Questions & Answers
      roar
      roar
    • RE: How to set/check a time stamp or candle ID

      @ikarus_ https://fxdreema.com/shared/LgnX2WX3

      posted in Questions & Answers
      roar
      roar
    • RE: Check Candle 1-5 if Price was higher then MA

      @siggi12345 I think the logic is right and you do understand the structure, but there is just some minor bug. Maybe the MA is not 9, instead its 20, etc... Does the EA make trades at all, even in "weird" situations? Share a link?

      posted in Questions & Answers
      roar
      roar
    • RE: Check Candle 1-5 if Price was higher then MA

      @siggi12345 I think I got it, try this version
      https://fxdreema.com/shared/cV7V8KE9e

      posted in Questions & Answers
      roar
      roar
    • RE: Setting up variables/constants that have non-numeric values

      @tonyramirez yes, usually integers do just fine.
      You can also set datatype as some enum type, then you'll get the drop-down menu in mt4/mt5.
      For example, timeframes datatype is ENUM_TIMEFRAMES
      https://docs.mql4.com/constants/chartconstants/enum_timeframes

      posted in Questions & Answers
      roar
      roar
    • RE: Profit Math

      @alphaomega I noticed a bug in my algo. Weird thing is, I remember fixing that bug before - maybe I shared you the wrong version...
      This should work:
      https://fxdreema.com/shared/VeKz6Pg7d

      posted in Questions & Answers
      roar
      roar
    • RE: Is there any way to store RSI value when a candle closes at its high or low? and

      @len-1 something like this?
      0_1602263421582_894e5327-bb2f-4dcd-8d0a-89340b5e067f-image.png

      posted in Questions & Answers
      roar
      roar
    • RE: Use the MACD Histogram

      @siggi12345 yes you can, the histogram is this indicator (weirdly enough)
      0_1602368443705_83d26916-d5c5-4b45-9e50-54532b75a4d0-image.png

      posted in Questions & Answers
      roar
      roar
    • RE: Profit Math

      @alphaomega no, average variable is reseted when block 8 begins its work.

      Area #1 is just for getting the total volume of open trades.
      The trades variable is useless, I forgot to delete it.

      posted in Questions & Answers
      roar
      roar
    • RE: Condition for date of a month

      @jjot here https://fxdreema.com/shared/JXEAQShWb

      posted in Questions & Answers
      roar
      roar
    • RE: how to set a variable that = 1% of balance

      @ajmd97fx you can use any MQL function.
      So here's the list, I guess 😄
      https://docs.mql4.com/
      https://www.mql5.com/en/docs

      posted in Questions & Answers
      roar
      roar
    • RE: Please help Test Expert Advisor.

      @tsheppo ok. Well, you might be optimist, but I think my graph is closer to the harsh reality.

      In your graph, trades almost never hit SL, even though the SL is incredibly tight. Doesnt sound credible to me.

      If you share the project, I can convert to mt5 and test with the smarter tester.

      posted in Questions & Answers
      roar
      roar
    • RE: Please help Test Expert Advisor.

      @seb-0 running some optimization rn..
      First thoughts

      • the EA trades quite rarely, especially on H1. Around 200 trades a year is OK, but I would be happier if it traded more - you get more statistical reliability. This is also why I chose a longer test period, from 2013
      • you have separate constants for "uplimit" and "downlimit". This makes some trouble, because you would logically expect the optimal limits to be symmetrical. A solution: use only one of them, "uplimit" for example, and define "downlimit" as "100-uplimit" in the block.
      posted in Questions & Answers
      roar
      roar
    • RE: Please help Test Expert Advisor.

      @seb-0 I agree, the levels should stay 40-60 or perhaps 30-70, no reason to try everything. Just thought you wanted to optimize them, as you had the constants. I do my testing on FXTM, they seem to have the data

      posted in Questions & Answers
      roar
      roar
    • RE: Please help Test Expert Advisor.

      @seb-0 the opimization looks okayish to me... At least the forward didnt completely kill it lol

      I did a final test with the best forward result, red lines mark the total sample period (6/2013 - 6/2019, half is forward). A bit worryingly, out-of-sample test seems to behave different than in-sample. This might mean the good optimization is just a coincidence, you get lots of pretty coincidences when you run 10000 tests.

      In conclusion, can't say anything for certain, maybe maybe maybe 😄 More trades would bring more confidence, to my experience...

      0_1602883163092_fecf8a1c-6036-462f-a73c-9a145da14e91-image.png

      0_1602883341148_9b12dd56-b80b-4405-8e8d-9127ab91af00-image.png

      posted in Questions & Answers
      roar
      roar
    • 1
    • 2
    • 13
    • 14
    • 15
    • 16
    • 17
    • 21
    • 22
    • 15 / 22