#MTF_ [i]RSI_MACD_MA_Ron_02

Miscellaneous
Implements a curve of type %1
0 Views
0 Downloads
0 Favorites
#MTF_ [i]RSI_MACD_MA_Ron_02
//+------------------------------------------------------------------+
//|                            MTF_[i]RSI_MACD_MA_Ron_02.mq4 
//| MTF by Zathar, mod c codobro
//+------------------------------------------------------------------+

#property indicator_chart_window
#property indicator_buffers 5
#property indicator_color1 Red
#property indicator_color2 White
#property indicator_color3 Aqua
#property indicator_color4 LightGreen
#property indicator_color5 DodgerBlue

extern int TimeFrame = 0;
extern int MovingAvg1=5;
extern int MovingAvg2=8;
extern int RSIPeriod=14;
extern int MACDfast=12;
extern int MACDslow=26;
extern int MACDsignal=9;

double Buffer0[];
double Buffer1[];
double Buffer2[];
double Buffer3[];
double Buffer4[];

int init()
  {
   //---- indicator line
   IndicatorShortName("MTF_[i]RSI_MACD_MA_Ron_02");
   SetIndexLabel(0,"MTF_[i]RSI_MACD_MA_Ron_02");
   SetIndexStyle(0,DRAW_ARROW);
   SetIndexBuffer(0, Buffer0);
   SetIndexArrow(0,242);
   SetIndexStyle(1,DRAW_ARROW);
   SetIndexBuffer(1, Buffer1);
   SetIndexArrow(1,241);
   SetIndexStyle(2,DRAW_LINE);
   SetIndexBuffer(2, Buffer2);
   SetIndexStyle(3,DRAW_LINE);
   SetIndexBuffer(3, Buffer3);
   SetIndexStyle(4,DRAW_LINE);
   SetIndexBuffer(4, Buffer4);


  }
//----
   return(0);
 

int start()
  {
   datetime TimeArray[];
   int    i,shift,limit,y=0,counted_bars=IndicatorCounted();
     
   ArrayCopySeries(TimeArray,MODE_TIME,Symbol(),TimeFrame); 
   
   limit=Bars-counted_bars+TimeFrame/Period();
   for(i=0,y=0;i<limit;i++) {
     if (Time[i]<TimeArray[y]) {y++;}   
     Buffer0[i]=iCustom(NULL,TimeFrame,"[i]RSI_MACD_MA_Ron_02",MovingAvg1,MovingAvg2,RSIPeriod,MACDfast,MACDslow,MACDsignal,0,y); 
     Buffer1[i]=iCustom(NULL,TimeFrame,"[i]RSI_MACD_MA_Ron_02",MovingAvg1,MovingAvg2,RSIPeriod,MACDfast,MACDslow,MACDsignal,1,y); 
     Buffer2[i]=iCustom(NULL,TimeFrame,"[i]RSI_MACD_MA_Ron_02",MovingAvg1,MovingAvg2,RSIPeriod,MACDfast,MACDslow,MACDsignal,2,y); 
     Buffer3[i]=iCustom(NULL,TimeFrame,"[i]RSI_MACD_MA_Ron_02",MovingAvg1,MovingAvg2,RSIPeriod,MACDfast,MACDslow,MACDsignal,3,y); 
     Buffer4[i]=iCustom(NULL,TimeFrame,"[i]RSI_MACD_MA_Ron_02",MovingAvg1,MovingAvg2,RSIPeriod,MACDfast,MACDslow,MACDsignal,4,y);                
   }
   return(0);
  }
//---

Comments

Markdown supported. Formatting help

Markdown Formatting Guide

Element Markdown Syntax
Heading # H1
## H2
### H3
Bold **bold text**
Italic *italicized text*
Link [title](https://www.example.com)
Image ![alt text](image.jpg)
Code `code`
Code Block ```
code block
```
Quote > blockquote
Unordered List - Item 1
- Item 2
Ordered List 1. First item
2. Second item
Horizontal Rule ---