Features of the mql5 language, subtleties and tricks - page 231

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Well, the choice is yours, but if someone told me that the older one is no longer being developed and all the latest development is on the newer one, I would think that my choice would be obvious (unless there were other circumstances weighing on it).
EDIT: However, given that your profile indicates that you are in the USA, it may also depend on which brokers you plan to use and which platforms they offer.Forum on trading, automated trading systems and testing trading strategies
Peculiarities of mql5 language, subtleties and techniques of work
fxsaber, 2023.01.07 23:01
There are two types of brokers, which translate the time in the USA/Europe. Because of this, in particular, the rollover time is shifted.
The broker type can be determined automatically.
The results of running on some brokers.
RannForex-Server - Europe MetaQuotes-Demo - Europe FXOpen-MT5 - USA Alpari-MT5 - Europe Tickmill-Live - USA ICMarketsSC-MT5-2 - USA Darwinex-Live - USA
At the moment the script produces quite different results. I do not recommend using MT5-calendar until you fully understand its peculiarities.
A very simple technique in MQL5 allows you to speed up backtests for free - memorisation of position/order indexes by type.
An example of speeding up the previously published quick code.
It makes sense to split positions/orders by types.
If you need an imaginary zero for any double.
DBL_EPSILON
The smallest number for which the condition 1.0+DBL_EPSILON != 1.0 holds.
2.2204460492503131e-016
DBL_EPSILON
The smallest number for which the condition 1.0+DBL_EPSILON != 1.0 is satisfied.
2.2204460492503131e-016
Thank you!
DBL_EPSILON
The smallest number that satisfies the condition 1.0+DBL_EPSILON != 1.0
2.2204460492503131e-016
Please excuse me for commenting in English, I do not speak Russian.
This means:
because the DBL_EPSILON is the relative error rate. relative means relative to the magnitude of the number.
at 1.0, the error rate = 1 * 2 .2204460492503131e-016 (DBL_EPSILON)
at d, the error rate = d * DBL_EPSILON .
The computer cannot differentiate between d and d * (1 + 0.5*DBL_EPSILON), so it encodes both of them to the same binary.So, you get true for the exact (binary) comparison ==
DBL_EPSILON
The smallest number for which the condition 1.0+DBL_EPSILON != 1.0 is satisfied.
2.2204460492503131e-016
This is a bad explanation, because.
Explanation of the definition of DBL_EPSILON: