Market Profile MetaTrader indicator — is a classic Market Profile implementation that can show the price density over time, outlining the most important price levels, value area, and control value of a given trading session. This indicator can be attached to timeframes between M1 and D1 and will show the Market Profile for daily, weekly, monthly, or even intraday sessions. Lower timeframes offer higher precision. Higher timeframes are recommended for better visibility. Six different color schemes are available to draw the profile's blocks. Drawing profiles as a plain color histogram is also possible. This indicator is based on bare price action and does not use any standard MetaTrader indicators. It is available for both MetaTrader 4 and MetaTrader 5 platforms.

Input parameters

  • Session (default = Daily) — trading session for market profile: Daily, Weekly, Monthly, or Intraday.
  • StartFromDate (default = __DATE__) — if StartFromCurrentSession is false, then the indicator will start drawing profiles from this date. It draws to the past. For example, if you set it 2018-01-20 and SessionsToCount is 2, then it will draw the profiles for 2018-01-20 and 2018-01-19.
  • StartFromCurrentSession (default = true) — if true, then the indicator starts drawing from today, else — from the date given in StartFromDate.
  • SessionsToCount (default = 2) — for how many trading sessions to draw the market profiles.
  • ColorScheme (default = Blue_to_Red) — color scheme for profile's blocks:
    • blue to red
    • red to green
    • green to blue
    • yellow to cyan
    • magenta to yellow
    • cyan to magenta
  • SingleColor (default = clrBlue) — if ColorScheme is set to Single_Color, this color will be used to draw market profiles.
  • MedianColor (default = clrWhite) — color of the control value (median).
  • ValueAreaColor (default = clrWhite) — color of the value area border.
  • ShowValueAreaRays (default = false) — if true, then the value area's High and Low price levels of the last session before the most current one will be projected to the right side of the chart.
  • ShowMedianRays (default = false) — if true, then the median of the penultimate session will be projected to the right side of the chart.
  • TimeShiftMinutes (default = 0) — time shift for the sessions, in minutes. Positive value will move the session start to the left; negative — to the right.
  • PointMultiplier (default = 1) — the higher it is, the wider are the profile's price boxes and the fewer are the chart objects. You can use it to reduce the indicator's load on CPU.
  • ThrottleRedraw (default = 0) — a delay in seconds that will be applied before each redraw of the profiles. You can use it to reduce the indicator's load on CPU.
  • EnableIntradaySessionN (default = true) — if true and Session is set to Intraday, then the indicator will attempt to drawn the intraday market profile #N on the chart.
  • IntradaySessionNStartTime (default = "HH:MM") — start time in HH:MM format for the intraday session #N.
  • IntradaySessionNEndTime (default = "HH:MM") — end time in HH:MM format for the intraday session #N.
  • IntradaySessionNColorScheme (default = Blue_to_Red) — color scheme for the intraday session #N.

Example

Market Profile Indicator Example MetaTrader Chart

The chart screenshot shows market profiles calculated and displayed for two daily Forex trading sessions. The timeframe is M30 and the right-hand daily session is still in progress. The earliest prices are blue and the latest prices are red. The medians and the value areas are marked with the white lines and display the most important price areas. Traders tend to return to those areas if the volume of the breakout movement is not too high. High-volume breakout out of these areas signifies a real breakout. You can read more about Market Profile in this short e-book: Book on Market Profile.

Downloads (ver. 1.08, 2018-05-28)

Market Profile for MetaTrader 4 in .zip

Market Profile for MetaTrader 4 in .mq4

Market Profile for MetaTrader 5 in .zip

Market Profile for MetaTrader 5 in .mq5

Discussion

Warning! If you do not know how to install this indicator, please read the MetaTrader Indicators Tutorial.

Do you have any suggestions or questions regarding this indicator? You can always discuss Market Profile with the other traders and MQL programmers on the indicators forums.

Changelog

1.08 — 2018-05-28

  • Added smart color graduation depending on timeframe and session type.
  • Added an option to project the Median (Point of Control) of the previous session to the right side of the chart.
  • Added single color scheme.
  • Added PointMultiplier input parameter to allow traders to set wider profile box, helping with indicator's performance.
  • Added ThrottleRedraw input parameter to delay indicator's display updates, helping to reduce its load on the CPU.
  • Fixed a potential bug when incorrect chart object naming routine could cause glitchy display of the market profile.
  • Changed hard initialization failure to a soft one — this will prevent input parameters from resetting when incorrect timeframe and session type combination is used.

1.07 — 2018-02-06

  • Added support for up to four intraday sessions.
  • Added three new color schemes for drawing the market profile.
  • Some minor code tweaks and improvements.

1.06 — 2017-11-30

  • Added proper object cleanup when Market Profile is used with chart templates.

1.05 — 2017-11-23

  • Added optional display for the previous session's Value Area High/Low lines.
  • Added time shift input parameter to move the sessions across time zones.

1.04 — 2016-11-07

  • Fixed "Array out of range" errors.

1.03 — 2016-01-25

  • Added support for three sessions: daily, weekly, and monthly.
  • Fixed chart object deletion to only delete indicator's own objects.
  • Optimized execution speed.
  • Increased the range of supported timeframes.
  • Added inline indicator description.
  • Improved interface (enumerated input parameters).
  • Fixed some potential "Array out of range" errors.
  • Code rewritten completely to comply with the current MQL4 and MQL5 standards.

1.01 — 2011-12-11

  • Fixed compatibility issues due to new coding conventions in MQL5.

1.00 — 2010-07-23

  • Original version of Market Profile released for MT4 and MT5.