Предыдущая тема :: Следующая тема |
Автор |
Сообщение |
ivanoff
Зарегистрирован: 27.01.2006 Сообщения: 5 Откуда: ???????????
|
Добавлено: Пн Янв 30, 2006 2:36 pm Заголовок сообщения: ????????? ??????? |
|
|
????????? ?????. ?????? ???? ???? ???????????. ??????????? ?????? ?? ????????:
//+------------------------------------------------------------------+
//| Chaikin.mq4 |
//| Copyright © 2005, GuRu |
//| vip6967@bk.ru |
//+------------------------------------------------------------------+
#property copyright "Copyright © 2005, GuRu"
#property link "vip6967@bk.ru"
#property indicator_separate_window
#property indicator_buffers 2
#property indicator_color1 Blue
#property indicator_color2 Red
//---- input parameters
extern int nPeriod=11;
extern int screen=1;
//---- buffers
double ChaikinBuff1[];
double ChaikinBuff2[];
//+------------------------------------------------------------------+
//| Custom indicator initialization function |
//+------------------------------------------------------------------+
int init()
{
//---- indicators
SetIndexStyle(0,DRAW_LINE);
SetIndexBuffer(0,ChaikinBuff1);
SetIndexStyle(1,DRAW_LINE);
SetIndexBuffer(1,ChaikinBuff2);
//----
return(0);
}
//+------------------------------------------------------------------+
//| Custor indicator deinitialization function |
//+------------------------------------------------------------------+
int deinit()
{
//---- TODO: add your code here
//----
return(0);
}
//+------------------------------------------------------------------+
//| Custom indicator iteration function |
//+------------------------------------------------------------------+
int start()
{
int BeginBars=0;
int shift=0;
int i=0;
double ich=0;
double ich1=0;
int counted_bars=IndicatorCounted();
//---- TODO: add your code here
BeginBars=Bars-nPeriod-1;
if (screen==2) { BeginBars=150; }
shift=BeginBars;
while (shift>0)
{
ich1=((Close[shift+1]-Low[shift+1])-(High[shift+1]-Close[shift+1]))
/(High[shift+1]-Low[shift+1])*Volume[shift+1];
ich=((Close[shift]-Low[shift])-(High[shift]-Close[shift]))
/(High[shift]-Close[shift])*Volume[shift];
ich=ich+ich1;
ChaikinBuff2[shift]=ich;
ich1=0;
i=shift+nPeriod;
while (i>0)
{
ich=ChaikinBuff2[i];
ich1=ich1+ich;
i--;
}
ich1=ich1/nPeriod;
ChaikinBuff1[shift]=ich1;
shift--;
}
//----
return(0);
} |
|
Вернуться к началу |
|
|
KimIV Admin
Зарегистрирован: 24.01.2006 Сообщения: 958 Откуда: ??????
|
Добавлено: Пн Янв 30, 2006 9:13 pm Заголовок сообщения: Re: ????????? ??????? |
|
|
ivanoff писал(а): | ??????????? ?????? ?? ???????? |
??? ... ? ???? ?? ???? ?? ????????. ? ???? ? ?????? ??????? ???????... ?????... ???? ?? ????????... _________________ ??? ????? ? ???? ??????? ????? ? ??????? ???????? ???, ? ??????? ? ???? ?????? ? ??????? ???????? ????... |
|
Вернуться к началу |
|
|
ivanoff
Зарегистрирован: 27.01.2006 Сообщения: 5 Откуда: ???????????
|
Добавлено: Пн Янв 30, 2006 9:44 pm Заголовок сообщения: |
|
|
????. ? ?? ???? ???????. |
|
Вернуться к началу |
|
|
vadsura
Зарегистрирован: 28.03.2006 Сообщения: 3
|
Добавлено: Вт Апр 11, 2006 3:45 am Заголовок сообщения: ????????? ??????? 2 |
|
|
?? ????? MQL4 ???????? ??? ??????????. |
|
Вернуться к началу |
|
|
|