Ozymandias Indicator For MT5

Ozymandias Indicator For MT5

Table Of Contents:

  1. Ozymandias Indicator For MT5
  2. Installing the Ozymandias Indicator For MT5
  3. Parameters of the Ozymandias Indicator For MT5
  4. Buffers of the Ozymandias Indicator For MT5
  5. Main Parts Of The Code

The Ozymandias Indicator For MT5 is an excellent technical trading tool to have as a chartist because this indicator works exceptionally well when it comes to filtering out false price fluctuation which occur quite often in the market - the price action is channeled into a three layered band with the middle being a bi-color line which is used to indicate the market direction and bias so for bullish sectors in the market this line will be colored in blue and when the market is trading in a bearish sector then this line will be colored in red. The other two bands of the indicator there to act as upper and lower limits - the upper band is treated as an overbought region whereas the lower band is treated as an oversold margin or guideline - however these oversold and overbought regions have to be validated because there are far too many occurrences when the price action approaches these zones therefore what the trader may resort to doing is to upload another oscillator indicator which operates in a separate window from the indicator. It should be noted that this indicator is mainly intended to be used for determining the appropriate moment for closing and opening trades - the color changes are not intended for reversal-signal use.

FREE Ozymandias Indicator

Download the FREE Ozymandias Indicator for MT5.

To receive my email 100% sure: 
Put my email on your whitelist!

 

Partially Automated Trading Besides Your Day Job

Alerts In Real-Time When Divergences Occur

 

Installing the Ozymandias Indicator For MT5

After you downloaded the indicator via the form above you need to unzip the zip-file. Then you need to copy the file ozymandias.mq5 into the folder MQL5\Indicators of your MT5 installation. After that please restart MT5 and then you will be able to see the indicator in the list of indicators.

Parameters of the Ozymandias Indicator For MT5

The Ozymandias Indicator For MT5 has 3 parameters to configure.

input uint Length=2; input  ENUM_MA_METHOD MAType=MODE_SMA; input int Shift=0;   // Ñäâèã èíäèêàòîðà ïî ãîðèçîíòàëè â áàðàõ 

Buffers of the Ozymandias Indicator For MT5

The Ozymandias Indicator For MT5 provides 4 buffers.

SetIndexBuffer(0,IndBuffer,INDICATOR_DATA); SetIndexBuffer(1,ColorIndBuffer,INDICATOR_COLOR_INDEX); SetIndexBuffer(2,UpBuffer,INDICATOR_DATA); SetIndexBuffer(3,DnBuffer,INDICATOR_DATA); 

Main Parts Of The Code

int OnCalculate(const int rates_total,    // êîëè÷åñòâî èñòîðèè â áàðàõ íà òåêóùåì òèêå                 const int prev_calculated,// êîëè÷åñòâî èñòîðèè â áàðàõ íà ïðåäûäóùåì òèêå                 const datetime &time[],                 const double &open[],                 const double &high[],                 const double &low[],                 const double &close[],                 const long &tick_volume[],                 const long &volume[],                 const int &spread[])   { //--- ïðîâåðêà êîëè÷åñòâà áàðîâ íà äîñòàòî÷íîñòü äëÿ ðàñ÷¸òà    if(BarsCalculated(ATR_Handle) lt rates_total       || BarsCalculated(HMA_Handle) lt rates_total       || BarsCalculated(LMA_Handle) lt rates_total       || rates_total lt min_rates_total) return(RESET); //--- îáúÿâëåíèå ïåðåìåííûõ    int to_copy,limit,trend0,nexttrend0;    double hh,ll,maxl0,minh0,lma,hma,atr,ATR[],HMA[],LMA[];    static int trend1,nexttrend1;    static double maxl1,minh1; //--- ðàñ÷¸ò ñòàðòîâîãî íîìåðà limit äëÿ öèêëà ïåðåñ÷¸òà áàðîâ    if(prev_calculated gt rates_total || prev_calculated lt =0)// ïðîâåðêà íà ïåðâûé ñòàðò ðàñ÷¸òà èíäèêàòîðà      {       limit=rates_total-min_rates_total-1; // ñòàðòîâûé íîìåð äëÿ ðàñ÷¸òà âñåõ áàðîâ       trend1=0;       nexttrend1=0;       maxl1=0;       minh1=9999999;      }    else limit=rates_total-prev_calculated;  // ñòàðòîâûé íîìåð äëÿ ðàñ÷¸òà òîëüêî íîâûõ áàðîâ    to_copy=limit+1; //--- êîïèðóåì âíîâü ïîÿâèâøèåñÿ äàííûå â ìàññèâû    if(CopyBuffer(ATR_Handle,0,0,to_copy,ATR) lt =0) return(RESET);    if(CopyBuffer(HMA_Handle,0,0,to_copy,HMA) lt =0) return(RESET);    if(CopyBuffer(LMA_Handle,0,0,to_copy,LMA) lt =0) return(RESET); //--- èíäåêñàöèÿ ýëåìåíòîâ â ìàññèâàõ êàê â òàéìñåðèÿõ      ArraySetAsSeries(close,true);    ArraySetAsSeries(high,true);    ArraySetAsSeries(low,true);    ArraySetAsSeries(ATR,true);    ArraySetAsSeries(HMA,true);    ArraySetAsSeries(LMA,true); //---    nexttrend0=nexttrend1;    maxl0=maxl1;    minh0=minh1; //--- îñíîâíîé öèêë ðàñ÷¸òà èíäèêàòîðà    for(int bar=limit; bar gt =0 && !IsStopped(); bar--)      {       hh=high[ArrayMaximum(high,bar,Length)];       ll=low[ArrayMinimum(low,bar,Length)];       lma=LMA[bar];       hma=HMA[bar];       atr=ATR[bar]/2;       trend0=trend1;       //---       if(nexttrend0==1)         {          maxl0=MathMax(ll,maxl0);           if(hma lt maxl0 && close[bar] lt low[bar+1])            {             trend0=1;             nexttrend0=0;             minh0=hh;            }         }       //---       if(nexttrend0==0)         {          minh0=MathMin(hh,minh0);           if(lma gt minh0 && close[bar] gt high[bar+1])            {             trend0=0;             nexttrend0=1;             maxl0=ll;            }         }       //---       if(trend0==0)         {          if(trend1!=0.0)            {             IndBuffer[bar]=IndBuffer[bar+1];             ColorIndBuffer[bar]=1;            }          else            {             IndBuffer[bar]=MathMax(maxl0,IndBuffer[bar+1]);             ColorIndBuffer[bar]=1;            }          UpBuffer[bar]=IndBuffer[bar]+atr;          DnBuffer[bar]=IndBuffer[bar]-atr;         }       else         {          if(trend1!=1)            {             IndBuffer[bar]=IndBuffer[bar+1];             ColorIndBuffer[bar]=0;            }          else            {             IndBuffer[bar]=MathMin(minh0,IndBuffer[bar+1]);             ColorIndBuffer[bar]=0;            }          UpBuffer[bar]=IndBuffer[bar]+atr;          DnBuffer[bar]=IndBuffer[bar]-atr;         }       //---       if(bar)         {          nexttrend1=nexttrend0;          trend1=trend0;          maxl1=maxl0;          minh1=minh0;         }      } //---        return(rates_total);   } //+------------------------------------------------------------------+ 

 

About Me

I'm Mike Semlitsch the owner of PerfectTrendSystem.com. My trading career started in 2007. Since 2013 I have helped thousands of traders to take their trading to the next level. Many of them are now constantly profitable traders. 

The following performance was achieved by me while trading live in front of hundreds of my clients:

Connect With Me:  

Results From 5 Months!
This service starts soon! Be the first who get's notified when it begins!

This FREE Indicator Can Transform
Your Trading!

FREE Indicator + Telegram Group


Request the Ultimate Double Top/Bottom Indicator which is used by 10,000+ traders.