• Información general
  • Comentarios (2)
  • Discusión (42)
  • Novedades

Range Bars

The robust charting solution that enables creating custom live range bar charts on the MetaTrader 4 trading platform.

You can apply all of the standard and custom indicators and technical studies directly to the range bar charts and you can run EAs directly on these charts as well* (for details see text below the input summary).

To create a range bar chart you need to attach the Range Bar indicator to a standard time frame (1 minute is recommended) and use the indicator's settings to generate a live custom chart that will be displayed on an offline chart of your choice. All of the available settings are described below:

Bar type definition

  • Candle size (in pips for Forex pairs and in points for others).

Display settings

  • Display on offline chart (M2, M3, M4, M6, M7, M8, M9 or M10).
  • Apply template to offline chart (name of the template to apply to the range bars chart)
  • Automatically open offline chart (true/false)
  • Build history for number of days.
  • Reset Open on each trading day.
  • Override start of trading day.
  • Re-calculate chart on history updates.
  • Minimum chart update interval (defined in milliseconds).

ATR based bar size calculation

  • Enabled (true/false).
  • Daily ATR period.
  • Percentage of ATR to calculate candle size (high to low).

Alerts and Info

  • Sound signal on new bar (true/false).
  • Only signal reversal bars (true/false).
  • Use Alert Window to display signal (true/false).
  • Sound file to play on bullish bar.
  • Sound file to play on bearish bar.
  • Color of High threshold indicator.
  • Color of Low threshold indicator.
  • Color of an inactive threshold indicator.

* EAs can be used directly on the offline chart, however, a small tweak is required, so you need to have access to your EA source code. Below is an EA skeleton example that is capable of running directly on the offline chart:

#property strict
//| Expert initialization function                                   |
int OnInit()
   // You need to initialize a time to call the OnTimer event.
   // It is used to call OnTick whenever the Bid price changes.
   // The check is made every 250 ms, which should be sufficient.
//| Expert deinitialization function                                 |
void OnDeinit(const int reason)
   // Remember to destroy timer in the OnDeinit event.

//| Expert tick function                                             |
void OnTick()
   // This is where all of your EA trading logic resides.
   // I just write to the log in this example...
   Print("OnTick function call - bid = "+(string)Bid);
//| The OnTimer function is used to call OnTick()                    |
//| whenever the Bid price changes.                                  |
void OnTimer()
   static double prevBid = 0; 
   if(Bid != prevBid)
      prevBid = Bid;
kowtung 2019.05.13 02:18 

Very good indicator, recommend!!


Zentrader2015 2018.06.29 12:51 

The Range Bars are awesome! fits perfectly into my strategy and much nicer and easier to trade than renko IMO.

Versión 1.7 2019.06.04
Added option for overwriting the start time of trading day
Versión 1.6 2019.05.27
Added additional synchronization setting “Build history starting from date”. This setting overrides the value set in “Build history for number of days” and lets you precisely define the chart's anchor point in history via date and time of the first processed 1-minute bar.
Versión 1.5 2019.04.15
Added more offline timeframes
Versión 1.4 2019.01.14
Maintenance release
Fixed template problem where an EA from the template has not been attached.
Versión 1.3 2018.12.02
Added optional template loading and optional auto open for range bar chart
Versión 1.2 2018.05.28
Maintenance release
Historical charts are now built using data from the chart where the indicator has been attached (for example: M1, M5, M15, etc.)
Versión 1.1 2017.11.09
Bug fixes