Skip to content
All library documents

Using Embedded Economic Calendar Data for News Strategy Backtesting

Article MQL5 articles

Summary

The article describes preparing an MQL5 news filter for Strategy Tester use by storing economic calendar events in a static CSV resource. Static data addresses the tester’s lack of access to live calendar updates and limited historical event retention, while allowing tests to reuse a consistent event set. The proposed event records include date, time, currency, description, importance, and actual, forecast, and previous values.

User inputs control the date range, the time window around an event, currency selection, and impact levels. The implementation initializes these filters, loads event data, and checks for matches as new bars appear. The article shows filter output and frames this work as groundwork for later strategy testing; it does not report a trading performance evaluation or establish that a news strategy has an edge. Results depend on the completeness, accuracy, and timestamp handling of the imported calendar data, and the provided testing discussion is limited to a video reference rather than detailed quantitative evidence.

Key ideas

  • Static event data makes economic calendar filters usable in Strategy Tester runs without live news access.
  • A CSV resource can store event timing, affected currency, description, importance, and reported values.
  • Inputs allow filtering by event date, time relative to the event, currency, and impact level.
  • The MQL5 logic checks event matches on bar changes and reports filtered events.
  • The article demonstrates event filtering but provides no quantitative evidence that a news-based strategy is profitable.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.