Execution Cost and Fill Quality Auditor
- Yardımcı programlar
- Sürüm: 1.11
- Güncellendi: 23 Ekim 2026
Shows what each closed trade earned after commission, swap and fees, by symbol, session, hour, weekday or month.
FEATURES
- Rebuilds each trade from its deals, costs apart from gross.
- Net result, R, summary, breakdowns, cost alarm, CSV export.
HOW TO USE IT
1. Attach it to a chart.
2. Choose the window and table.
3. Read the panel or export the CSV.
PARAMETERS
InpRange, InpFilterMagic, InpRiskPercent, InpFixedStopPips, InpBreakdown.
LIMITATIONS
- Trades with no opening deal inside the window are counted, not reconstructed. At the default setting, a position opened before the window, or a netting reversal whose side opened partly before it, can give a row whose volume and entry price cover only the in-window openings while its profit covers the whole close, and nothing counts that row. At the default setting, a netting reversal that closes a side opened before the window overstates the side it opens; that side can fail to close in the audit and then appears in neither the table nor the excluded count.
- R is relative, not the risk taken: the percentage model uses the balance or equity at attach time.
- Costs and prices come from the deals; R comes from your risk model.
- The cost budget fires when the cost exceeds the configured share of gross profit. Cost is shown as a positive amount; the deal records keep their own sign.
- Fill deviation is not reported. The panel is empty in the Strategy Tester, which reads account history.
COMPATIBILITY
Any symbol, netting or hedging. Native MQL5, no DLLs.
SUPPORT
Questions through the MQL5 message system. First reply within two working days.
MEASUREMENT DISCLOSURE
The costs and the prices this tool reports are read directly from the deal records. The volume is read from them too, from the deals inside the window only, except the volume of the trade a netting reversal opens, which is a reconstruction rather than a reading. The R multiple is not: it is derived from the risk model you configure, so it is a relative measure against your own configured risk. Fill deviation is deliberately excluded, because MetaTrader does not retain the quote an order was originally priced against.
That statement does not make every row reconcile at the default setting, which audits the whole account; the first limitation above says when. If you set a magic filter, a position built by more than one Expert Advisor cannot be reported exactly, because the filtered out leg leaves volume and entry price describing only part of the position while profit and cost cover all of it. Rather than print a row that does not reconcile, those trades are counted and disclosed on the panel in the same way as trades with no opening deal inside the selected window.
PARAMETERS IN DETAIL
- InpFilterMagic: audit one Expert Advisor by magic number. 0 audits the whole account. Manual trades carry no magic number set by an Expert Advisor, so any filter excludes them.
- InpRange: the audit window. Last 24 hours, 3 days, 7 days, 30 days, 90 days, or a custom number of days.
- InpCustomDays: the number of days used when the custom option is selected.
- InpRefreshMinutes: how often the audit is repeated, in minutes.
- InpRiskPercent: the percentage you intend to risk on each trade, used to turn every trade into an R multiple. It applies one flat money figure to every trade, so it is accurate only when position sizing is constant.
- InpFixedStopPips: an optional fixed stop distance in pips. When set, it overrides the percentage model and gives a more faithful R figure across different symbols and sizes.
- InpUseEquity: take the percentage model from equity instead of balance.
- InpBudgetAlert: turn the cost budget monitor on or off.
- InpBudgetPct: warn when commission, swap and fees exceed this share of gross profit. Default 25. Cost is shown as a positive amount, while the deal records keep their own sign. The budget is only evaluated once there are three closed trades and the gross result is positive.
- InpAlertPopup: raise a terminal popup and a journal entry when the budget is exceeded.
- InpCorner, InpOffsetX, InpOffsetY, InpBgColor, InpBorderColor, InpHeaderColor: panel placement and colours.
- InpBreakdown: which attribution table is shown, by symbol, session, hour, weekday or month.
- InpShowBreakdown: show or hide the breakdown table.
- InpCsvOnRefresh: write the CSV file on every refresh.
- InpCsvFolder: the folder under the terminal's MQL5 Files directory. The file is execution_audit.csv, one row per trade: symbol, open and close time, direction, volume, entry and exit price, gross result, commission, swap, fees, net result, holding time and the R multiple.
ATTRIBUTION NOTES
Session buckets are calculated in GMT from the offset your own terminal reports, in five buckets: Asia, London, New York, the London and New York overlap, and off hours. The hour table is in server time, not GMT. The offset is read once when the tool is attached, so if your broker changes its offset for daylight saving, re-attach the tool after the change.
The percentage risk model and the assumed stop distance model are alternatives, not a pair. Set the stop distance and it overrides the percentage, because a distance is volume aware and therefore stays faithful across symbols and sizes.
The figures update on the interval you set. The tool opens no positions, places no orders and modifies nothing on the account.
If you have used it, I would welcome a short review of what worked and what did not.
