Forum

Stationarity indicator and how to see if the market is moving with commitment

Here is an indicator for anyone who is interested in using it. I created it both to practice some coding techniques and also to be able to have a look at some market dynamics that interest me. Maybe some of you will find it interesting as well. This was my first time really working with objects on

MT4 and MT5: OnTimer sometimes stops updating?

Hi all. I am seeing an intermittent problem on MT4 and MT5 (although it happens more on MT4 so far) where Initializing the Timer works fine, no errors, and the OnTimer function begins to work ok. But then at some later point, OnTimer appears to stop updating/being triggered. I am unsure of the

Trading Days of the Month and other business day math

I wanted to try Larry Williams' Trading Day of Month strategies, but I had a hard time figuring out how to calculate the current trading day of the month accurately (basically similar in concept to business day calculations in Excel). I could not find code on this site for it ... I am SURE someone

Very strange - Error 4074 - out of memory when using iTime for multi timeframe functionality?

I am working on an EA in MT4, trying to take advantage of some multi-timeframe features. In summary, my current EA runs on a PERIOD_D1 tf and I want to check the current time on PERIOD_D1 tf to manage housekeeping functionality. To isolate the problem I made the following toy EA. This is all that is

Function call to get Balance & Equity Graph image?

Hi all, While tightening up automating my testing process I would like to grab the balance and equity graph at the end of a test. There is a right-click method for this on the balance/equity curve chart, so I am hoping there is a matching set of functionality in mql5. I have searched for a function

Github: sometimes seeing mq5 and mqh files as "binary"

Hi all, I ran into a problem that seems to have surfaced for me recently. Some of my .mq5 and .mqh files are incorrectly seen by Github as binary. I have not changed anything in my ea-creation workflow (ie: using a third party text editor/IDE). Once this happens to a file on Github, I cannot get

Strategy Tester *SLOWED DOWN* by function in OnTimer??

I've noticed a surprising thing: An EA that I am coding has an OnTimer function call in it that I *thought* that the Strategy Tester would ignore. I inserted it there because during normal, non-testing runtime, I wanted it to run a utility every once a few minutes that would loop through history

Broker time zone offsets, DST, and the strategy tester

Maybe I am not using the right search terms in google or on this forum (if so, please enlighten me so I can find the golden key). I cannot find easy solutions to aligning my timezone with my broker's timezone in the strategy tester ... and take into account DST. So, I kludged my way through it as

Your experices with Auto Optimization in MT4?

Hi - question for the crowd here: It seems like about 10 years ago, batch or auto optimization (ie: something similar to this - https://www.mql5.com/en/articles/1467 ) seemed to be the big up-and-coming thing. Difficult to pull off, but some of the forum posts around that time were hopeful that it

Best method to automatically update history files in MT4?

Hi all, done some research on the following, and have hit a wall. In MT4 this seems to be more difficult to do, compared to MT5. Maybe I'm not searching in the right corner of the forum or internet? Wouldn't be surprised if I missed stuff. Hope someone here can point me in the right direction for