//+--------------------------------------------------------------------------------------+ // O N E T H I R D | // Copyright © RickD BJF Trading Group 2006 | // http://fxstrategy.ca | // | //Experts http://fxstrategy.ca/experts.php SALE! 50% OFF | //Indicators http://fxstrategy.ca/products.php SALE!50% OFF | //Digital Filters Strategy http://fxstrategy.ca/digital_filtrs.php SALE!50% OFF | //Trading Signals http://fxstrategy.ca/signals.php Two weeks FREE! No CC. | // forex calendar, research, article .... | //+--------------------------------------------------------------------------------------+ #property copyright "© RickD BJF Trading Group 2006" #property link "http://fxstrategy.ca/products.php" //---- #define major 1 #define minor 0 //---- #property indicator_chart_window #property indicator_buffers 4 #property indicator_color1 OrangeRed #property indicator_color2 DodgerBlue #property indicator_color3 OrangeRed #property indicator_color4 DodgerBlue //---- double ExtMapBuffer1[]; double ExtMapBuffer2[]; double ExtMapBuffer3[]; double ExtMapBuffer4[]; //+------------------------------------------------------------------+ //| | //+------------------------------------------------------------------+ void init() { SetIndexBuffer(0, ExtMapBuffer1); SetIndexBuffer(1, ExtMapBuffer2); SetIndexBuffer(2, ExtMapBuffer3); SetIndexBuffer(3, ExtMapBuffer4); //---- SetIndexStyle(0, DRAW_HISTOGRAM, 0, 1); SetIndexStyle(1, DRAW_HISTOGRAM, 0, 1); SetIndexStyle(2, DRAW_HISTOGRAM, 0, 3); SetIndexStyle(3, DRAW_HISTOGRAM, 0, 3); } //+------------------------------------------------------------------+ //| | //+------------------------------------------------------------------+ void deinit() { //---- } //+------------------------------------------------------------------+ //| | //+------------------------------------------------------------------+ void start() { int counted = IndicatorCounted(); if(counted < 0) return (-1); //---- if (counted > 0) counted--; int limit = Bars-counted; //---- for(int i = 0; i < limit; i++) { double third = (High[i] - Low[i]) / 3; //---- if(Close[i] > High[i] - third) { ExtMapBuffer1[i] = Low[i]; ExtMapBuffer2[i] = High[i]; ExtMapBuffer3[i] = MathMin(Open[i], Close[i]); ExtMapBuffer4[i] = MathMax(Open[i], Close[i]); } //---- if(Close[i] < Low[i] + third) { ExtMapBuffer1[i] = High[i]; ExtMapBuffer2[i] = Low[i]; ExtMapBuffer3[i] = MathMax(Open[i], Close[i]); ExtMapBuffer4[i] = MathMin(Open[i], Close[i]); } } } //+------------------------------------------------------------------+
Sample
Analysis
Market Information Used:
Series array that contains the highest prices of each bar
Series array that contains the lowest prices of each bar
Series array that contains close prices for each bar
Series array that contains open prices of each bar
Indicator Curves created:
Implements a curve of type DRAW_HISTOGRAM
Indicators Used:
Custom Indicators Used:
Order Management characteristics:
Other Features: