//+-----------+ //| PriceLine | //+-----------+ #property copyright "Copyright 2005 Ron Thompson" #property link "http://www.forexmt4.com/" //---- indicator settings #property indicator_separate_window #property indicator_buffers 1 #property indicator_color1 White //#property indicator_color2 Green //#property indicator_color3 Red //#property indicator_color4 Green //#property indicator_color5 Red //#property indicator_color6 LawnGreen //#property indicator_color7 Red //#property indicator_color8 Yellow //---- buffers double ExtMapBuffer1[]; //Yellow //double ExtMapBuffer2[]; //Green //double ExtMapBuffer3[]; //Red //double XBuffer[]; //White //double ZBuffer[]; //White //double ExtMapBuffer6[]; //Green //double ExtMapBuffer7[]; //Red //double ExtMapBuffer8[]; //Yellow extern int extDraw4HowLong = 500; // bar open handling int bartime; //Objects int uniq=0; //+-----------+ //| Init | //+-----------+ int init() { ObjectsDeleteAll(); SetIndexBuffer(0,ExtMapBuffer1); //Yellow SetIndexStyle(0, DRAW_LINE, STYLE_SOLID, 2); /* SetIndexBuffer(1,ExtMapBuffer2); //Green SetIndexStyle(1, DRAW_LINE, STYLE_SOLID, 2); SetIndexBuffer(2,ExtMapBuffer3); //Red SetIndexStyle(2, DRAW_LINE, STYLE_SOLID, 2); // 233 up arrow // 234 down arrow // 158 little dot // 159 big dot // 168 open square // 120 box with X SetIndexStyle(3,DRAW_ARROW); SetIndexBuffer(3, XBuffer); //Green SetIndexArrow(3,233); SetIndexStyle(4,DRAW_ARROW); SetIndexBuffer(4, ZBuffer); //Red SetIndexArrow(4,234); SetIndexBuffer(5,ExtMapBuffer6); //Green SetIndexStyle(5, DRAW_ARROW); SetIndexArrow(5,233); SetIndexBuffer(6,ExtMapBuffer7); //Red SetIndexStyle(6, DRAW_ARROW); SetIndexArrow(6,234); SetIndexBuffer(7,ExtMapBuffer8); //Yellow SetIndexStyle(7, DRAW_ARROW); SetIndexArrow(7,120); */ Print("Init complete"); } //+-----------+ //| DE-Init | //+-----------+ int deinit() { int i; for( i=0; i<Bars; i++ ) { ExtMapBuffer1[i]=0; //ExtMapBuffer2[i]=0; //ExtMapBuffer3[i]=0; //XBuffer[i]=0; //ZBuffer[i]=0; //ExtMapBuffer6[i]=0; //ExtMapBuffer7[i]=0; //ExtMapBuffer8[i]=0; } ObjectsDeleteAll(); Print("DE-Init complete"); } //+-----------+ //| Each Tick | //+-----------+ int start() { int pos; // draw only bar[0] if not at open of bar if(bartime==Time[0]) { ExtMapBuffer1[0] = Close[0]*Volume[0]; } else { bartime=Time[0]; for(pos = extDraw4HowLong; pos >= 0; pos--) { ExtMapBuffer1[pos] = Close[pos]*Volume[pos]; }//for }//if }//start
Sample
Analysis
Market Information Used:
Series array that contains open time of each bar
Series array that contains close prices for each bar
Series array that contains tick volumes of each bar
Indicator Curves created:
Implements a curve of type DRAW_LINE
Implements a curve of type DRAW_ARROW
Implements a curve of type DRAW_ARROW
Indicators Used:
Custom Indicators Used:
Order Management characteristics:
Other Features: