2 Äëÿ ðàáîòû èíäèêàòîðà ñëåäóåò ïîëîæèòü ôàéëû
\r
6 â ïàïêó (äèðåêòîðèþ): MetaTrader\experts\include\
\r
9 â ïàïêó (äèðåêòîðèþ): MetaTrader\indicators\
\r
11 //+SSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSS+
\r
13 //| Copyright © 2006, Nikolay Kositsin |
\r
14 //| Khabarovsk, farria@mail.redcom.ru |
\r
15 //+SSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSS+
\r
16 #property copyright "Nikolay Kositsin"
\r
17 #property link "farria@mail.redcom.ru"
\r
18 //---- îòðèñîâêà èíäèêàòîðà â ãëàâíîì îêíå
\r
19 #property indicator_chart_window
\r
20 //---- êîëè÷åñòâî èíäèêàòîðíûõ áóôôåðîâ
\r
21 #property indicator_buffers 6
\r
22 //---- öâåòà èíäèêàòîðà
\r
23 #property indicator_color1 Lime
\r
24 #property indicator_color2 Lime
\r
25 #property indicator_color3 Red
\r
26 #property indicator_color4 Red
\r
27 #property indicator_color5 Gray
\r
28 #property indicator_color6 Gray
\r
29 //---- ÂÕÎÄÍÛÅ ÏÀÐÀÌÅÒÐÛ ÈÍÄÈÊÀÒÎÐÀ þþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþþææ+
\r
30 extern int Length = 5; // ãëóáèíà ñãëàæèâàíèÿ
\r
31 extern int Phase = 100; // ïàðàìåòð ñãëàæèâàíèÿ, èçìåíÿþùèéñÿ â ïðåäåëàõ -100 ... +100, âëèÿåò íà êà÷åñòâî ïåðåõîäíîãî ïðîöåññà;
\r
32 extern int Input_Price_Customs = 0;//Âûáîð öåí, ïî êîòîðûì ïðîèçâîäèòñÿ ðàñ÷¸ò èíäèêàòîðà
\r
33 //(0-CLOSE, 1-OPEN, 2-HIGH, 3-LOW, 4-MEDIAN, 5-TYPICAL, 6-WEIGHTED, 7-Heiken Ashi Close, 8-SIMPL, 9-TRENDFOLLOW, 10-0.5*TRENDFOLLOW,
\r
34 //11-Heiken Ashi Low, 12-Heiken Ashi High, 13-Heiken Ashi Open, 14-Heiken Ashi Close.)
\r
35 //---- æææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææææ+
\r
36 //---- ââåäåíèå ôóíêöèè digits() äëÿ óñòàíîâêè ôîðìàòà òî÷íîñòè (êîëè÷åñòâî çíàêîâ ïîñëå äåñÿòè÷íîé òî÷êè) äëÿ âèçóàëèçàöèè çíà÷åíèé èíäèêàòîðà
\r
37 int digits(){return(Digits);}
\r
38 //---- Ââåäåíèå ôóíêöèè COUNT_begin() äëÿ âû÷èñëåíèÿ íîìåðà áàðà, íà÷èíàÿ ñ êîòîðîãî áóäåò îòðèñîâûâàòüñÿ èíäèêàòîð
\r
39 int COUNT_begin(){return(30);}
\r
40 //---- óñòàíîâêà çíà÷åíèé èíäèêàòîðà, êîòîðûå íå áóäóò âèäèìû íà ãðàôèêå
\r
42 //---- ëåéáà äëÿ èíäèêàòîðà
\r
43 string Label="JJMA";
\r
44 //---- âêëþ÷åíèå â òåêñò èíäèêàòîðà åãî îñíîâíîãî òåêñòà
\r
45 #include <3Color.mqh>
\r
46 //---- ââåäåíèå ôóíêöèè INDICATOR -------------------------------------------------------------------------+
\r
47 //---- îáðàùåíèå ê èñõîäíîìó èíäèêàòîðó äëÿ ïîëó÷åíèÿ èõîäíûõ çíà÷åíèé
\r
48 double INDICATOR(int INDICATOR.bar)
\r
50 return( iCustom(NULL,0,"JJMA",Length,Phase,0,Input_Price_Customs,0,INDICATOR.bar) );
\r
52 //---- ----------------------------------------------------------------------------------------------------+