I too am looking for a range bar indicator. Range bars are not dependent on time
but on depth of price action. Excellent for showing range and TREND
eg. if the user sets the range bar to be 10, then after every 10 pip, a
new candlestick bar is created. The length of time taken to create the
bar doesnt matter. So if eurusd moved up from 100, to 110 in 1minute,
then one candlestick bar would be completed. If eurusd moved up from
100, to 110 in 5 hours, then again only one candlestick bar would be
completed.
//+------------------------------------------------------------------+//| Ticks.mq4 |//| MetaQuotes |//| http://www.alpari-idc.ru/ru/experts/articles/ |//+------------------------------------------------------------------+#propertycopyright"Rosh"#propertylink"http://www.alpari-idc.ru/ru/experts/articles/"#propertyindicator_separate_window#propertyindicator_buffers1#propertyindicator_color1Navy//---- buffersexternintMaxDrawTicks=500;
doubleExtMapBuffer1[];
intmyBars;
inttickCounter;
intdelimeterCounter;
//+------------------------------------------------------------------+//| Custom indicator initialization function |//+------------------------------------------------------------------+intinit(){//---- indicatorsSetIndexStyle(0,DRAW_LINE);
SetIndexBuffer(0, ExtMapBuffer1);
SetIndexEmptyValue(0,0.0);
Print("Reduce ticks to Zero");
for(inti=Bars-1;i>=0;i--)ExtMapBuffer1[i]=0.0;
//----return(0);
}//+------------------------------------------------------------------+//| Custom indicator deinitialization function |//+------------------------------------------------------------------+intdeinit(){//----//----return(0);
}//+------------------------------------------------------------------+//| Let us move the massif |//+------------------------------------------------------------------+voidSetDelimeter(){//----stringdelimeterDate=TimeToStr(Time[0]);
if(myBars!=0){Print("Place the seperator");
inthandle=WindowFind("Ticks");
if(!ObjectCreate(delimeterDate,OBJ_VLINE,handle,Time[0],0)){Alert("Failed attemp at creation of seperator in the window ",
handle," On the time ",TimeToStr(CurTime()));
Print("Error No",GetLastError(),", The name of the seperator ",delimeterDate);
}else{ObjectSet(delimeterDate,OBJPROP_COLOR,DarkGreen);
ObjectSet(delimeterDate,OBJPROP_STYLE,STYLE_DASHDOT);
ObjectsRedraw();
}}//----return(0);
}//+------------------------------------------------------------------+//| Let us move the massif |//+------------------------------------------------------------------+voidShiftArray(){//----intV_lines;
stringdelimeterName;
datetimefirstTime;
intBarFirstTime;
if(tickCounter>2*MaxDrawTicks){for(inti=tickCounter;i>=MaxDrawTicks;i--)ExtMapBuffer1[i]=0.0;
tickCounter=MaxDrawTicks;
}for(intcnt=tickCounter;cnt>0;cnt--){ExtMapBuffer1[cnt]=ExtMapBuffer1[cnt-1];
}V_lines=ObjectsTotal();
for(intz=0;z<V_lines;z++){delimeterName=ObjectName(z);
if(ObjectFind(delimeterName)!=-1){if(ObjectType(delimeterName)==OBJ_VLINE){firstTime=ObjectGet(delimeterName,OBJPROP_TIME1);
BarFirstTime=iBarShift(NULL,0,firstTime);
firstTime=Time[BarFirstTime+1];
ObjectSet(delimeterName,OBJPROP_TIME1,firstTime);
}}}//----return(0);
}//+------------------------------------------------------------------+//|The sign of the new bar |//+------------------------------------------------------------------+boolisNewBar(){//----boolres=false;
if(myBars!=Bars){res=true;
myBars=Bars;
}//----return(res);
}//+------------------------------------------------------------------+//| Custom indicator iteration function |//+------------------------------------------------------------------+intstart(){intcounted_bars=IndicatorCounted();
//----if(isNewBar()){// To establish the seperatortickCounter++;
SetDelimeter();
ExtMapBuffer1[0]=Bid;
}else{tickCounter++;
ShiftArray();
ExtMapBuffer1[0]=Bid;
}//----return(0);
}//+------------------------------------------------------------------+
jb1975:
I too am looking for a range bar indicator. Range bars are not dependent on time
but on depth of price action. Excellent for showing range and TREND
Something I like to see as you have mentioned here is LinearPriceBar.mq4
This indicator is quite simple but very powerful to see sentiment without up and
down of the chart which is typically noise.
jb1975:
I too am looking for a range bar indicator. Range bars are not dependent on time but on depth of price action. Excellent for showing range and TREND
eg. if the user sets the range bar to be 10, then after every 10 pip, a new candlestick bar is created. The length of time taken to create the bar doesnt matter. So if eurusd moved up from 100, to 110 in 1minute, then one candlestick bar would be completed. If eurusd moved up from 100, to 110 in 5 hours, then again only one candlestick bar would be completed.
Thanks
Would be very grateful if someone could code this indicator
I've developed range bar charts for MT4 for one of my clients. It is a script which is similar to period_converter. It creates a new chart which can be opened in the offline mode. You can drop any indicator on it and trade on it too. It is updated in a real time and for history it models ticks based on 1M bars. Anywone interested in this product can contact me at www.mqlservice.net
right be such
try again, please.
eg. if the user sets the range bar to be 10, then after every 10 pip, a new candlestick bar is created. The length of time taken to create the bar doesnt matter. So if eurusd moved up from 100, to 110 in 1minute, then one candlestick bar would be completed. If eurusd moved up from 100, to 110 in 5 hours, then again only one candlestick bar would be completed.
Explanation of range bars here:
Range Bars
Thanks
Would be very grateful if someone could code this indicator
Babelfish translation of Ticks.mq4
I too am looking for a range bar indicator. Range bars are not dependent on time but on depth of price action. Excellent for showing range and TREND
Something I like to see as you have mentioned here is LinearPriceBar.mq4
This indicator is quite simple but very powerful to see sentiment without up and down of the chart which is typically noise.
I too am looking for a range bar indicator. Range bars are not dependent on time but on depth of price action. Excellent for showing range and TREND
eg. if the user sets the range bar to be 10, then after every 10 pip, a new candlestick bar is created. The length of time taken to create the bar doesnt matter. So if eurusd moved up from 100, to 110 in 1minute, then one candlestick bar would be completed. If eurusd moved up from 100, to 110 in 5 hours, then again only one candlestick bar would be completed.
Explanation of range bars here:
Range Bars
Thanks
Would be very grateful if someone could code this indicator
I've developed range bar charts for MT4 for one of my clients. It is a script which is similar to period_converter. It creates a new chart which can be opened in the offline mode. You can drop any indicator on it and trade on it too. It is updated in a real time and for history it models ticks based on 1M bars. Anywone interested in this product can contact me at www.mqlservice.net
Looking for Free Reliable Range Indicators ?
See here - Constant Range Detector. Scroll down to - Constant Range Indicators and Range Information