Skip to content
All library documents

Exporting Expert Advisor Backtest Equity to an Offline Chart

Article MQL5 code base

Summary

The document explains a utility for recording an Expert Advisor’s backtest equity data in a history file, then viewing that data as an offline chart. The workflow creates an instance of the class, updates it on each tick, saves the data when the test ends, copies the file from the tester directory into the platform’s history directory, and opens it through the offline chart menu.

An included example shows the utility alongside a simple order placing routine, but that trading logic is illustrative and does not establish a strategy or performance result. The document provides no details on the equity file format, chart aggregation, or validation of the recorded data. Its practical value is in inspecting a backtest’s equity path within the trading platform; conclusions drawn from the chart remain subject to the quality and assumptions of the underlying backtest.

Key ideas

  • The class records Expert Advisor backtest equity in a history file for offline chart display.
  • Update the equity record during ticks, then save and copy the file when the test ends.
  • The offline chart is opened from the platform’s history after the file is copied there.
  • The example’s order logic is not evidence of a profitable strategy.

Tags

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