Discussing the article: "MetaTrader 5 and the MQL5 Economic Calendar: How to Turn News into a Reproducible Trading System"
Thanks for the article - very interesting - I'll look into how it works.... I myself wanted to use wyb codes and ai agents to connect through news and twitter parser - ts to make... you can also organise a hybrid mql5 with ai agents....
Written by:
Если брокер учитывает переход на летнее/зимнее время — календарь автоматически подстраивается под этот переход
Correct me if something has changed in MQL5 API, but previously the calendar was adjusted to the current time zone taking into account DST, i.e. in summer function requests return time stamps, for example, in the UTC+3 zone, while a request of the same history section in winter will get events with stamps in the UTC+2 zone, if the server switches to DST and vice versa. Thus, to accurately upload calendar history for six months or more, you need to analyse the broker's time zone translation history. More details in codobase.
Also, the approach with linking calendar cache as a resource seems little practical and, in particular, provokes the errors mentioned in the article itself (like, don't forget to recompile the EA). Why not set the calendar cache in the input parameter as a file from the Common folder available for all agents?
- 2024.11.10
- www.mql5.com
and why quotes (in general all time stamps) are not kept for example in UTC ?
why dealers' ticks have different numerical representation of one and the same countdown of time
philosophical question :-) it's the way it's done, though it's wrong and causes problems on the spot.
ZЫ. so "historical news" is better to take from other sources.
And never need to "analyse the history of clock translation" - it's all there, it's a function of OS or system libraries. Google tzdata
how many bicycles can be made, and crooked ones at that
Previously, the calendar was adjusted to the current time zone taking into account DST, i.e. in summer function requests return time stamps, for example, in the UTC+3 zone, and a request for the same history section in winter will get events with stamps in the UTC+2 zone if the server switches to DST and back.
ZЫ. so "historical news" is better to take from other sources.
And you should never "analyse the history of clock translation" yourself - it's all there, it's a function of OS or system libraries. Google tzdata
how many bicycles can be made, and crooked ones at that
Other sources will not solve the problem, because it is buried in the way quotes are stored in MT5.
Show your straight bicycle first, and then give advice.
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Check out the new article: MetaTrader 5 and the MQL5 Economic Calendar: How to Turn News into a Reproducible Trading System.
The main problems of the modern news trader are fragmented toolset and the lack of a systematic, algorithmic trading workflow. It is pretty difficult to split your attention between your internet browser (browsing news sites) and your trading terminal while making trades.
A news trader's workflow looks like this: Quickly open the news calendar in your web browser and check for any changes in events → Quickly evaluate upcoming events and decide what and how to trade → Go to the MetaTrader 5 terminal – either place pending orders or sit at the terminal and wait for the news release to make a decision. In this scenario, the trader often experiences a loss of context, which leads to delays in reacting to news, which in turn leads to losses.
Do you want news trading to work like an engineering problem — with clear rules, repeatable results, and automated testing? The purpose of this article is to demonstrate the working architecture of a news layer for MetaTrader 5: a single data source, proper use of the calendar API, a filtering and caching mechanism, export of historical events to a resource for the tester, and automatic switching between Live and Tester — so that the same code produces deterministic results in both real time and historical data.
Author: MetaQuotes