XFisher_org_v1_Vol_Supr_Zer

Author: Copyright © 2005, TrendLaboratory Ltd.
0 Views
0 Downloads
0 Favorites
XFisher_org_v1_Vol_Supr_Zer
ÿþ//+---------------------------------------------------------------------+

//|                                     XFisher_org_v1_Vol_Supr_Zer.mq5 |

//|                              Copyright © 2006, TrendLaboratory Ltd. |

//|               http://finance.groups.yahoo.com/group/TrendLaboratory |

//|                                          E-mail: igorad2004@list.ru |

//+---------------------------------------------------------------------+

//| ;O @01>BK  8=48:0B>@0  A;54C5B  ?>;>68BL D09; SmoothAlgorithms.mqh |

//| 2 ?0?:C (48@5:B>@8N): :0B0;>3_40==KE_B5@<8=0;0\\MQL5\Include        |

//+---------------------------------------------------------------------+

//---- 02B>@AB2> 8=48:0B>@0

#property copyright "Copyright © 2005, TrendLaboratory Ltd."

//---- 02B>@AB2> 8=48:0B>@0

#property link      "http://finance.groups.yahoo.com/group/TrendLaboratory"

//---- =><5@ 25@A88 8=48:0B>@0

#property version   "1.11"

//---- >B@8A>2:0 8=48:0B>@0 2 >B45;L=>< >:=5

#property indicator_separate_window

//---- 4;O @0AG5B0 8 >B@8A>2:8 8=48:0B>@0 8A?>;L7>20=> 45AOBL 1CD5@>2

#property indicator_buffers 10

//---- 8A?>;L7>20=> H5ABL 3@0D8G5A:8E ?>AB@>5=89

#property indicator_plots   6

//+----------------------------------------------+

//| 0@0<5B@K >B@8A>2:8 >1;0:0 :0=0;0            |

//+----------------------------------------------+

//---- >B@8A>2:0 8=48:0B>@0 1 2 2845 F25B=>3> >1;0:0

#property indicator_type1   DRAW_FILLING

//---- 2 :0G5AB25 F25Bjd 8=48:0B>@0 8A?>;L7>20=K

#property indicator_color1  clrLavender

//---- >B>1@065=85 <5B:8 ;8=88 8=48:0B>@0

#property indicator_label1  "XFisher_org_v1_Vol Cloud"

//+----------------------------------------------+

//| 0@0<5B@K >B@8A>2:8 ;8=88 A>?@>B82;5=8O      |

//+----------------------------------------------+

//---- >B@8A>2:0 8=48:0B>@0 2 2845 ;8=88

#property indicator_type2   DRAW_LINE

//---- 2 :0G5AB25 F25B0 ;8=88 8=48:0B>@0 8A?>;L7>20= Teal F25B

#property indicator_color2 clrTeal

//---- ;8=8O 8=48:0B>@0 - HB@8E-?C=:B8@

#property indicator_style2  STYLE_DASHDOTDOT

//---- B>;I8=0 ;8=88 8=48:0B>@0 @02=0 1

#property indicator_width2  1

//---- >B>1@065=85 <5B:8 8=48:0B>@0

#property indicator_label2  "XFisher_org_v1_Vol Res"

//+----------------------------------------------+

//| 0@0<5B@K >B@8A>2:8 ;8=88 ?>445@6:8          |

//+----------------------------------------------+

//---- >B@8A>2:0 8=48:0B>@0 2 2845 ;8=88

#property indicator_type3   DRAW_LINE

//---- 2 :0G5AB25 F25B0 ;8=88 8=48:0B>@0 8A?>;L7>20= Red F25B

#property indicator_color3 clrRed

//---- ;8=8O 8=48:0B>@0 - HB@8E-?C=:B8@

#property indicator_style3  STYLE_DASHDOTDOT

//---- B>;I8=0 ;8=88 8=48:0B>@0 @02=0 1

#property indicator_width3  1

//---- >B>1@065=85 <5B:8 8=48:0B>@0

#property indicator_label3  "XFisher_org_v1_Vol Supr"

//+----------------------------------------------+

//| 0@0<5B@K >B@8A>2:8 8=48:0B>@0 Fisher_org_v1 |

//+----------------------------------------------+

//---- >B@8A>2:0 8=48:0B>@0 2 2845 F25B=>3> >1;0:0

#property indicator_type4   DRAW_FILLING

//---- 2 :0G5AB25 F25Bjd 8=48:0B>@0 8A?>;L7>20=K

#property indicator_color4  clrDodgerBlue,clrDeepPink

//---- >B>1@065=85 <5B:8 ;8=88 8=48:0B>@0

#property indicator_label4  "XFisher_org_v1_Vol"

//+----------------------------------------------+

//| 0@0<5B@K >B@8A>2:8 A83=0;L=KE 7=0G:>2       |

//+----------------------------------------------+

//---- >B@8A>2:0 8=48:0B>@0 2 2845 <=>3>F25B=KE 7=0G:>2

#property indicator_type5   DRAW_COLOR_ARROW

//---- 2 :0G5AB25 F25B>2 B@5EF25B=>9 38AB>3@0<<K 8A?>;L7>20=K

#property indicator_color5  clrLime,clrGray,clrMagenta

//---- 38AB>3@0<<K 8=48:0B>@0 - =5?@5@K2=0O :@820O

#property indicator_style5  STYLE_SOLID

//---- B>;I8=0 ;8=88 8=48:0B>@0 @02=0 2

#property indicator_width5  2

//---- >B>1@065=85 <5B:8 8=48:0B>@0

#property indicator_label5  "XFisher_org_v1_Vol Arrows"

//+----------------------------------------------+

//|  0@0<5B@K >B@8A>2:8 7=0G:>2                 |

//+----------------------------------------------+

//---- >B@8A>2:0 8=48:0B>@0 6 2 2845 F25B=>3> A8<2>;0

#property indicator_type6   DRAW_COLOR_ARROW

//---- 2 :0G5AB25 F25B>2 8=48:0B>@0 8A?>;L7>20=K

#property indicator_color6  clrAqua,clrYellow

//---- B>;I8=0 ;8=88 8=48:0B>@0 6 @02=0 4

#property indicator_width6  4

//---- >B>1@065=85 <5B:8 8=48:0B>@0

#property indicator_label6  "XFisher_org_v1_Vol ZeroSignal"

//+----------------------------------------------+

//| 0@0<5B@K >B>1@065=8O 3>@87>=B0;L=KE C@>2=59 |

//+----------------------------------------------+

#property indicator_level1 0.0

#property indicator_levelcolor clrGray

#property indicator_levelstyle STYLE_SOLID

#property indicator_levelwidth 1

//+----------------------------------------------+

//|  1JO2;5=85 :>=AB0=B                         |

//+----------------------------------------------+

#define RESET 0       // :>=AB0=B0 4;O 2>72@0B0 B5@<8=0;C :><0=4K =0 ?5@5AG5B 8=48:0B>@0

//+----------------------------------------------+

//|  ?8A0=85 :;0AA0 CXMA                        |

//+----------------------------------------------+

#include <SmoothAlgorithms.mqh> 

//+----------------------------------------------+

//---- >1JO2;5=85 ?5@5<5==KE :;0AA0 CXMA 87 D09;0 SmoothAlgorithms.mqh

CXMA XMA1,XMA2;

//+----------------------------------------------+

//|  >1JO2;5=85 ?5@5G8A;5=89                     |

//+----------------------------------------------+

/*enum Smooth_Method - ?5@5G8A;5=85 >1JO2;5=> 2 D09;5 SmoothAlgorithms.mqh

  {

   MODE_SMA_,  // SMA

   MODE_EMA_,  // EMA

   MODE_SMMA_, // SMMA

   MODE_LWMA_, // LWMA

   MODE_JJMA,  // JJMA

   MODE_JurX,  // JurX

   MODE_ParMA, // ParMA

   MODE_T3,    // T3

   MODE_VIDYA, // VIDYA

   MODE_AMA,   // AMA

  }; */

//+----------------------------------------------+

//|  >1JO2;5=85 ?5@5G8A;5=89                     |

//+----------------------------------------------+

enum ENUM_APPLIED_PRICE_ //"8? :>=AB0=BK

  {

   PRICE_CLOSE_ = 1,     //PRICE_CLOSE

   PRICE_OPEN_,          //PRICE_OPEN

   PRICE_HIGH_,          //PRICE_HIGH

   PRICE_LOW_,           //PRICE_LOW

   PRICE_MEDIAN_,        //PRICE_MEDIAN

   PRICE_TYPICAL_,       //PRICE_TYPICAL

   PRICE_WEIGHTED_,      //PRICE_WEIGHTED

   PRICE_SIMPL_,         //PRICE_SIMPL_

   PRICE_QUARTER_,       //PRICE_QUARTER_

   PRICE_TRENDFOLLOW0_,  //PRICE_TRENDFOLLOW0_

   PRICE_TRENDFOLLOW1_,  // TrendFollow_2 Price 

   PRICE_DEMARK_         // Demark Price 

  };

//+----------------------------------------------+

//| E>4=K5 ?0@0<5B@K 8=48:0B>@0                 |

//+----------------------------------------------+

input uint FLength=7;                             // 3;C18=0 CA@54=5=8O

input Smooth_Method MA_SMethod=MODE_JJMA;         // 5B>4 A3;06820=8O

input uint MA_Length=5;                           // ;C18=0 A3;06820=8O                    

input int MA_Phase=15;                            // ?0@0<5B@ A3;06820=8O,

//---- 4;O JJMA 87<5=ONI89AO 2 ?@545;0E -100 ... +100, 2;8O5B =0 :0G5AB2> ?5@5E>4=>3> ?@>F5AA0;

//---- ;O VIDIA MB> ?5@8>4 CMO, 4;O AMA MB> ?5@8>4 <54;5==>9 A:>;L7OI59                  

input ENUM_APPLIED_PRICE_ IPC=PRICE_CLOSE_;       // F5=>20O :>=AB0=B0

input ENUM_APPLIED_VOLUME VolumeType=VOLUME_TICK; // >1JQ< 

input int HighLevel=+150;                         // C@>25=L ?5@5:C?;5==>AB8

input int LowLevel=-150;                          // C@>25=L ?5@5?@>40==>AB8

input int Shift=0;                                // !4283 8=48:0B>@0 ?> 3>@87>=B0;8 2 10@0E 

//+----------------------------------------------+

//---- >1JO2;5=85 48=0<8G5A:8E <0AA82>2, :>B>@K5 2 40;L=59H5< 1C4CB 8A?>;L7>20=K 2 :0G5AB25 8=48:0B>@=KE 1CD5@>2

double UpIndBuffer[],DnIndBuffer[];

double UpIndBuffer1[],DnIndBuffer1[];

double IndBuffer[],TriggerBuffer[];

double ArrBuffer[],ColorArrBuffer[];

double ZrSigBuffer[],ColorZrSigBuffer[];

//---- >1JO2;5=85 F5;>G8A;5==KE ?5@5<5==KE =0G0;0 >BAG5B0 40==KE

int min_rates_total,min_rates_1,AtrPeriod;

//+------------------------------------------------------------------+

//| Custom indicator initialization function                         |

//+------------------------------------------------------------------+  

int OnInit()

  {

//---- 8=8F80;870F8O ?5@5<5==KE =0G0;0 >BAG5B0 40==KE

   min_rates_1=int(FLength)+1;

   min_rates_total=min_rates_1+GetStartBars(MA_SMethod,MA_Length,MA_Phase);

   AtrPeriod=15;

//---- ?@52@0I5=85 48=0<8G5A:>3> <0AA820 IndBuffer[] 2 8=48:0B>@=K9 1CD5@

   SetIndexBuffer(0,UpIndBuffer,INDICATOR_DATA);

//---- ?@52@0I5=85 48=0<8G5A:>3> <0AA820 TriggerBuffer[] 2 8=48:0B>@=K9 1CD5@

   SetIndexBuffer(1,DnIndBuffer,INDICATOR_DATA);

//---- >ACI5AB2;5=85 A42830 8=48:0B>@0 1 ?> 3>@87>=B0;8 =0 Shift

   PlotIndexSetInteger(0,PLOT_SHIFT,Shift);

//---- >ACI5AB2;5=85 A42830 =0G0;0 >BAG5B0 >B@8A>2:8 8=48:0B>@0 =0 min_rates_total

   PlotIndexSetInteger(0,PLOT_DRAW_BEGIN,min_rates_total);

//---- CAB0=>2:0 7=0G5=89 8=48:0B>@0, :>B>@K5 =5 1C4CB 2848<K =0 3@0D8:5

   PlotIndexSetDouble(0,PLOT_EMPTY_VALUE,EMPTY_VALUE);

//---- 70?@5B =0 >B>1@065=85 7=0G5=89 8=48:0B>@0 2 ;52>< 25@E=5< C3;C >:=0 8=48:0B>@0

   PlotIndexSetInteger(0,PLOT_SHOW_DATA,false);

//----

//---- ?@52@0I5=85 48=0<8G5A:>3> <0AA820 2 8=48:0B>@=K9 1CD5@

   SetIndexBuffer(2,UpIndBuffer1,INDICATOR_DATA);

//---- >ACI5AB2;5=85 A42830 =0G0;0 >BAGQB0 >B@8A>2:8 8=48:0B>@0

   PlotIndexSetInteger(1,PLOT_DRAW_BEGIN,min_rates_total);

//---- CAB0=>2:0 7=0G5=89 8=48:0B>@0, :>B>@K5 =5 1C4CB 2848<K =0 3@0D8:5

   PlotIndexSetDouble(1,PLOT_EMPTY_VALUE,EMPTY_VALUE);

//---- >ACI5AB2;5=85 A42830 8=48:0B>@0 ?> 3>@87>=B0;8

   PlotIndexSetInteger(1,PLOT_SHIFT,Shift);

//---- 70?@5B =0 >B>1@065=85 7=0G5=89 8=48:0B>@0 2 ;52>< 25@E=5< C3;C >:=0 8=48:0B>@0

   PlotIndexSetInteger(1,PLOT_SHOW_DATA,false);

//----   

//---- ?@52@0I5=85 48=0<8G5A:>3> <0AA820 2 8=48:0B>@=K9 1CD5@

   SetIndexBuffer(3,DnIndBuffer1,INDICATOR_DATA);

//---- >ACI5AB2;5=85 A42830 =0G0;0 >BAGQB0 >B@8A>2:8 8=48:0B>@0

   PlotIndexSetInteger(2,PLOT_DRAW_BEGIN,min_rates_total);

//---- CAB0=>2:0 7=0G5=89 8=48:0B>@0, :>B>@K5 =5 1C4CB 2848<K =0 3@0D8:5

   PlotIndexSetDouble(2,PLOT_EMPTY_VALUE,EMPTY_VALUE);

//---- >ACI5AB2;5=85 A42830 8=48:0B>@0 ?> 3>@87>=B0;8

   PlotIndexSetInteger(2,PLOT_SHIFT,Shift);

//---- 70?@5B =0 >B>1@065=85 7=0G5=89 8=48:0B>@0 2 ;52>< 25@E=5< C3;C >:=0 8=48:0B>@0

   PlotIndexSetInteger(2,PLOT_SHOW_DATA,false);

//----

//---- ?@52@0I5=85 48=0<8G5A:>3> <0AA820 IndBuffer[] 2 8=48:0B>@=K9 1CD5@

   SetIndexBuffer(4,IndBuffer,INDICATOR_DATA);

//---- ?@52@0I5=85 48=0<8G5A:>3> <0AA820 TriggerBuffer[] 2 8=48:0B>@=K9 1CD5@

   SetIndexBuffer(5,TriggerBuffer,INDICATOR_DATA);

//---- >ACI5AB2;5=85 A42830 8=48:0B>@0 1 ?> 3>@87>=B0;8 =0 Shift

   PlotIndexSetInteger(3,PLOT_SHIFT,Shift);

//---- >ACI5AB2;5=85 A42830 =0G0;0 >BAG5B0 >B@8A>2:8 8=48:0B>@0 =0 min_rates_total

   PlotIndexSetInteger(3,PLOT_DRAW_BEGIN,min_rates_total);

//---- CAB0=>2:0 7=0G5=89 8=48:0B>@0, :>B>@K5 =5 1C4CB 2848<K =0 3@0D8:5

   PlotIndexSetDouble(3,PLOT_EMPTY_VALUE,EMPTY_VALUE);

//---- 70?@5B =0 >B>1@065=85 7=0G5=89 8=48:0B>@0 2 ;52>< 25@E=5< C3;C >:=0 8=48:0B>@0

   PlotIndexSetInteger(3,PLOT_SHOW_DATA,false);

//----

//---- ?@52@0I5=85 48=0<8G5A:>3> <0AA820 2 8=48:0B>@=K9 1CD5@

   SetIndexBuffer(6,ArrBuffer,INDICATOR_DATA);

//---- ?@52@0I5=85 48=0<8G5A:>3> <0AA820 2 F25B>2>9, 8=45:A=K9 1CD5@   

   SetIndexBuffer(7,ColorArrBuffer,INDICATOR_COLOR_INDEX);

//---- >ACI5AB2;5=85 A42830 8=48:0B>@0 ?> 3>@87>=B0;8

   PlotIndexSetInteger(4,PLOT_SHIFT,Shift);

//---- >ACI5AB2;5=85 A42830 =0G0;0 >BAG5B0 >B@8A>2:8 8=48:0B>@0

   PlotIndexSetInteger(4,PLOT_DRAW_BEGIN,min_rates_total);

//---- CAB0=>2:0 7=0G5=89 8=48:0B>@0, :>B>@K5 =5 1C4CB 2848<K =0 3@0D8:5

   PlotIndexSetDouble(4,PLOT_EMPTY_VALUE,EMPTY_VALUE);

//---- A8<2>; 4;O 8=48:0B>@0

   PlotIndexSetInteger(4,PLOT_ARROW,110);

//----  

//---- ?@52@0I5=85 48=0<8G5A:>3> <0AA820 ExtLineBuffer 2 8=48:0B>@=K9 1CD5@

   SetIndexBuffer(8,ZrSigBuffer,INDICATOR_DATA);

//---- >ACI5AB2;5=85 A42830 =0G0;0 >BAGQB0 >B@8A>2:8 8=48:0B>@0

   PlotIndexSetInteger(5,PLOT_DRAW_BEGIN,min_rates_total+AtrPeriod);

//--- 70?@5B =0 >B@8A>2:C 8=48:0B>@>< ?CABKE 7=0G5=89

   PlotIndexSetDouble(5,PLOT_EMPTY_VALUE,EMPTY_VALUE);

//---- >ACI5AB2;5=85 A42830 8=48:0B>@0?> 3>@87>=B0;8

   PlotIndexSetInteger(5,PLOT_SHIFT,Shift);

//---- 70?@5B =0 >B>1@065=85 7=0G5=89 8=48:0B>@0 2 ;52>< 25@E=5< C3;C >:=0 8=48:0B>@0

   PlotIndexSetInteger(5,PLOT_SHOW_DATA,false);

//---- 2K1>@ A8<2>;0 4;O >B@8A>2:8

   PlotIndexSetInteger(5,PLOT_ARROW,108);

//---- ?@52@0I5=85 48=0<8G5A:>3> <0AA820 2 F25B>2>9, 8=45:A=K9 1CD5@   

   SetIndexBuffer(9,ColorZrSigBuffer,INDICATOR_COLOR_INDEX);

//----

//---- 8=8F80;870F88 ?5@5<5==>9 4;O :>@>B:>3> 8<5=8 8=48:0B>@0

   string shortname;

   StringConcatenate(shortname,"XFisher_org_v1_Vol_Supr(",FLength,")");

//---- A>740=85 8<5=8 4;O >B>1@065=8O 2 >B45;L=>< ?>4>:=5 8 2> 2A?;K20NI59 ?>4A:07:5

   IndicatorSetString(INDICATOR_SHORTNAME,shortname);

//---- >?@545;5=85 B>G=>AB8 >B>1@065=8O 7=0G5=89 8=48:0B>@0

   IndicatorSetInteger(INDICATOR_DIGITS,0);

//---- 7025@H5=85 8=8F80;870F88

   return(INIT_SUCCEEDED);

  }

//+------------------------------------------------------------------+

//| Custom indicator iteration function                              |

//+------------------------------------------------------------------+

int OnCalculate(const int rates_total,    // :>;8G5AB2> 8AB>@88 2 10@0E =0 B5:CI5< B8:5

                const int prev_calculated,// :>;8G5AB2> 8AB>@88 2 10@0E =0 ?@54K4CI5< B8:5

                const datetime &time[],

                const double &open[],

                const double& high[],     // F5=>2>9 <0AA82 <0:A8<C<>2 F5=K 4;O @0AG5B0 8=48:0B>@0

                const double& low[],      // F5=>2>9 <0AA82 <8=8<C<>2 F5=K  4;O @0AG5B0 8=48:0B>@0

                const double &close[],

                const long &tick_volume[],

                const long &volume[],

                const int &spread[])

  {

//---- ?@>25@:0 :>;8G5AB20 10@>2 =0 4>AB0B>G=>ABL 4;O @0AG5B0

   if(rates_total<min_rates_total) return(RESET);



//---- >1JO2;5=8O ;>:0;L=KE ?5@5<5==KE 

   int first,bar;

   double smax,smin,price,wpr,value,res1,res2,fish,vol,xvol;

   static double value_prev,fish_prev;



//---- @0AG5B AB0@B>2>3> =><5@0 first 4;O F8:;0 ?5@5AG5B0 10@>2

   if(prev_calculated>rates_total || prev_calculated<=0) // ?@>25@:0 =0 ?5@2K9 AB0@B @0AG5B0 8=48:0B>@0

     {

      first=min_rates_1;                           // AB0@B>2K9 =><5@ 4;O @0AG5B0 2A5E 10@>2

      value_prev=0.0;

      IndBuffer[first-1]=fish_prev=0.0;

     }

   else first=prev_calculated-1; // AB0@B>2K9 =><5@ 4;O @0AG5B0 =>2KE 10@>2



//---- >A=>2=>9 F8:; @0AG5B0 8=48:0B>@0

   for(bar=first; bar<rates_total && !IsStopped(); bar++)

     {

      smax=DBL_MIN;

      smin=DBL_MAX;

      //----

      for(int iii=0; iii<int(FLength); iii++)

        {

         int barx=bar-iii;

         smax=MathMax(smax,high[barx]);

         smin=MathMin(smin,low[barx]);

        }

      if(smax==smin) smax+=_Point;

      price=PriceSeries(IPC,bar,open,low,high,close);

      wpr=(price-smin)/(smax-smin);

      value=(wpr-0.5)+0.67*value_prev;

      value=MathMin(value,+DBL_MAX);

      value=MathMax(value,-DBL_MAX);

      res1=1.0-value;

      if(!res1) res1=1.0;

      res2=(1.0+value)/(1.0-value);

      if(res2<0.0000001) res2=1.0;

      fish=0.5*MathLog(res2)+0.5*fish_prev;

      if(VolumeType==VOLUME_TICK) vol=double(tick_volume[bar]);

      else vol=double(volume[bar]);

      IndBuffer[bar]=fish*vol; //4><=>605< 7=0G5=85 >AF8;;OB>@0 =0 >1JQ<  

      IndBuffer[bar]=100*XMA1.XMASeries(min_rates_1,prev_calculated,rates_total,MA_SMethod,MA_Phase,MA_Length,IndBuffer[bar],bar,false);

      xvol=XMA2.XMASeries(min_rates_1,prev_calculated,rates_total,MA_SMethod,MA_Phase,MA_Length,vol,bar,false);  //CA@54=O5< >1JQ<  

      UpIndBuffer[bar]=UpIndBuffer1[bar]=HighLevel*xvol;

      DnIndBuffer[bar]=DnIndBuffer1[bar]=LowLevel*xvol;

      TriggerBuffer[bar]=IndBuffer[bar-1];



      ColorArrBuffer[bar]=1;

      ArrBuffer[bar]=EMPTY_VALUE;

      if(IndBuffer[bar]>UpIndBuffer[bar])

        {

         if(IndBuffer[bar]>=TriggerBuffer[bar])

           {

            ColorArrBuffer[bar]=0;

            ArrBuffer[bar]=0.0;

           }

        }



      if(IndBuffer[bar]<DnIndBuffer[bar])

        {

         if(IndBuffer[bar]<=TriggerBuffer[bar])

           {

            ColorArrBuffer[bar]=2;

            ArrBuffer[bar]=0.0;

           }

        }

      //---- 

      ColorZrSigBuffer[bar]=2;

      ZrSigBuffer[bar]=EMPTY_VALUE;

      

      if(IndBuffer[bar-1]>0.0 && IndBuffer[bar]<=0.0)

        {

         ZrSigBuffer[bar]=0.0;

         ColorZrSigBuffer[bar]=1;

        }

      if(IndBuffer[bar-1]<0.0 && IndBuffer[bar]>=0.0)

        {

         ZrSigBuffer[bar]=0.0;

         ColorZrSigBuffer[bar]=0;

        }

      //----

      if(bar<rates_total-1)

        {

         value_prev=value;

         fish_prev=fish;

        }

     }

//----     

   return(rates_total);

  }

//+------------------------------------------------------------------+

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 ---