Loading…

Currency Exposure Wheel

A cosmetic alternative to a plain text exposure table. The underlying numbers are the same a table would show - which currencies the open book is net long or short, and by how much relative to each other - but arranged as a wheel makes an unbalanced book visible at a glance: one or two spokes dwarfing the rest says "this account is really one concentrated currency bet" far faster than reading down a column of numbers. Exposure is measured on the same simplified LOTS-based approximation most currency-exposure and currency-strength panels use: a Buy of L lots on a BASEQUOTE symbol adds +L to the base currency's running exposure and -L to the quote currency's; a Sell reverses both signs. This is not a true notional value calculation - the quote-currency side actually scales with the traded price, not 1:1 with lot size - and is documented here plainly rather than presented as an exact currency total. The harder problem this indicator solves is a plumbing one, not a math one: chart line objects in MQL4 are anchored by time and price, not screen pixels, so a wheel that needs to sit in a fixed spot on screen has to convert its pixel geometry to time/price coordinates fresh on every redraw via ChartXYToTimePrice(). The wheel redraws on a timer and on every chart scroll/zoom event so it stays pinned to the same screen location instead of visibly drifting as the visible price range changes. Notes and limitations - Exposure is a lots-based approximation, not true notional value - see above. Do not read the numbers as account-currency amounts. - Only plain 6-character FX-style symbol names (e.g. "EURUSD") split cleanly into a 3-letter base and 3-letter quote; any open order on a symbol shorter than 6 characters is skipped entirely and contributes nothing to the wheel. - Only OPEN MARKET orders (OP_BUY/OP_SELL) count. Pending orders carry no current exposure and are ignored, matching how exposure is normally understood. - Tracks at most 12 distinct currencies at once; a book touching more than that silently stops adding new spokes past the 12th (documented cap, not a crash). - The wheel is a live snapshot redrawn on a timer, not a plotted historical series - it always shows the account's current open exposure, never a past state. - Because every spoke position is recomputed from the current chart view, a very fast succession of scroll/zoom events can produce a brief visible flicker while objects are deleted and recreated; this is a cosmetic side effect of the pixel- anchoring technique, not a data problem.

Indicator · MT5 · v1.0 · Free

About Currency Exposure Wheel

Currency Exposure Wheel is an indicator for MetaTrader 5. It has 9 settings, such as Center x, Center y and Radius. MQL source code included.

Files in the download: CurrencyExposureWheel.ex5, CurrencyExposureWheel.mq5, CurrencyExposureWheel.txt.

Settings

SettingDefaultWhat it does
Center x300Wheel centre, pixels from the LEFT edge of the chart
Center y150Wheel centre, pixels from the TOP edge of the chart
Radius90Wheel outer radius, pixels
Rim segments24Number of straight segments approximating the rim circle
Long colorclrLimeSpoke colour for net-long currencies
Short colorclrOrangeRedSpoke colour for net-short currencies
Rim colorclrSilverRim circle colour
Refresh seconds5Seconds between automatic redraws
Font size9Currency label font size

How to install

  1. Download the ZIP from your PolyMaria library and unzip it.
  2. In MetaTrader 5 open File → Open Data Folder, then go to MQL5 → Indicators.
  3. Copy the .mq5 file(s) there. Put any .mqh files in MQL5 → Include.
  4. Open the .mq5 file in MetaEditor and press Compile (F7) if MetaTrader does not show it.
  5. Drag the indicator from the Navigator onto a chart and adjust the settings.

Download the PDF guide

Tags: MT5 Indicator · MQL5 Source Code

MetaTrader 4 & 5 indicators · PolyMaria