Central Pivot Range
Central Pivot Range is a well-established intraday reference on other platforms and largely absent from MetaTrader 4's default set. The formula itself is simple and public: Pivot = (High+Low+Close)/3, BC = (High+Low)/2, TC = (Pivot-BC)+Pivot, all computed from the prior completed calendar day. What a bare three-line implementation leaves out is the two things CPR is actually read for in practice: how wide today's range is compared with recent days (a narrow CPR is commonly read as a coiled, breakout-prone day; a wide one as an already- volatile, range-bound day), and how today's band sits relative to yesterday's (higher value, lower value, unchanged, or one band fully inside or outside the other) - the standard two-day relationship classification used alongside CPR elsewhere. This indicator computes both automatically: width is compared against the trailing average of a configurable number of prior days, and the two-day relationship walks back to the previous day's own CPR band and classifies the overlap. Both are printed as a small chart label rather than left for the trader to compare five overlapping numbers by eye. Notes and limitations - Levels use the prior calendar day's raw high/low/close; on a symbol with an irregular trading day (indices, some CFDs, weekends) the prior day's range can be unusually narrow or wide, which distorts the CPR and its width classification for that one day. - The width classification is relative to the symbol's own recent history (InpWidthLookback days), not an absolute threshold - a "Wide" reading on a naturally quiet symbol and a "Wide" reading on a naturally volatile one are not directly comparable to each other. - The relationship classification (Higher/Lower/Unchanged/Inside/ Outside/Overlapping Value) compares only the BC-TC band, not the R1- S1 or wider pivot levels some CPR variants also include - those are not computed by this indicator. - The on-chart label reflects only the current (rightmost) bar's classification; it does not label every historical day.
Indicator · MT4 · v1.0 · Free
About Central Pivot Range
Central Pivot Range is an indicator for MetaTrader 4. It has 5 settings, such as Show zone fill, Show label and Width lookback. MQL source code included.
Files in the download: CentralPivotRange.ex4, CentralPivotRange.mq4, CentralPivotRange.txt.
Settings
| Setting | Default | What it does |
|---|---|---|
| Show zone fill | true | Shade the BC-TC band |
| Show label | true | Print width/relationship classification as chart text |
| Width lookback | 5 | Trailing days averaged for the width classification |
| Narrow factor | 0.5 | Today's width below (factor * trailing average) = Narrow |
| Wide factor | 1.5 | Today's width above (factor * trailing average) = Wide |
How to install
- Download the ZIP from your PolyMaria library and unzip it.
- In MetaTrader 4 open File → Open Data Folder, then go to MQL4 → Indicators.
- Copy the .mq4 file(s) there. Put any .mqh files in MQL4 → Include.
- Open the .mq4 file in MetaEditor and press Compile (F7) if MetaTrader does not show it.
- Drag the indicator from the Navigator onto a chart and adjust the settings.
Tags: Pivot Points · Trailing Stop & Break-even · MT4 Indicator · MQL4 Source Code