#property copyright "Kalenzo" #property link "bartlomiej.gorski@gmail.com" #property indicator_separate_window #property indicator_buffers 2 #property indicator_color1 DodgerBlue #property indicator_color2 Lime extern int RsiPeriod = 14; extern int MaType = 1; extern int MaPeriod = 50; extern int TimeFrame = 60; double g_ibuf_92[]; double g_ibuf_96[]; double g_ibuf_100[]; double g_ibuf_104[]; int init() { IndicatorBuffers(4); SetIndexBuffer(0, g_ibuf_92); SetIndexBuffer(1, g_ibuf_96); SetIndexStyle(0, DRAW_LINE, STYLE_SOLID, 2); SetIndexStyle(1, DRAW_LINE, STYLE_SOLID, 1); SetIndexBuffer(2, g_ibuf_100); SetIndexBuffer(3, g_ibuf_104); IndicatorShortName("MTF RSI " + tf()); return (0); } int deinit() { return (0); } int start() { int l_shift_0; int l_bars_4 = Bars; int li_8 = iBars(Symbol(), TimeFrame); for (int li_12 = 0; li_12 < li_8; li_12++) g_ibuf_100[li_12] = iRSI(Symbol(), TimeFrame, RsiPeriod, PRICE_CLOSE, li_12); for (int li_16 = 0; li_16 < li_8; li_16++) g_ibuf_104[li_16] = iMAOnArray(g_ibuf_100, 0, MaPeriod, 0, MaType, li_16); for (int l_index_20 = 0; l_index_20 < l_bars_4; l_index_20++) { l_shift_0 = iBarShift(Symbol(), TimeFrame, Time[l_index_20]); g_ibuf_92[l_index_20] = g_ibuf_100[l_shift_0]; g_ibuf_96[l_index_20] = g_ibuf_104[l_shift_0]; } return (0); } string tf() { switch (TimeFrame) { case PERIOD_M1: return ("M(1)"); case PERIOD_M5: return ("M(5)"); case PERIOD_M15: return ("M(15)"); case PERIOD_M30: return ("M(30)"); case PERIOD_H1: return ("H(1)"); case PERIOD_H4: return ("H(4)"); case PERIOD_D1: return ("D(1)"); case PERIOD_W1: return ("W(1)"); case PERIOD_MN1: return ("MN(1)"); } return ("Unknown timeframe"); }
Sample
Analysis
Market Information Used:
Series array that contains open time of each bar
Indicator Curves created:
Implements a curve of type DRAW_LINE
Indicators Used:
Relative strength index
Moving average indicator
Custom Indicators Used:
Order Management characteristics:
Other Features: