编码帮助 - 页 723

 

嗨,Mladen先生, 大家 ......我希望我是在正确的地方, 我需要一个帮助, ,请 修改 这些指标, 以便 当它 越过 天蓝色 的颜色线时 改变 品色线 ......例如 交叉 上升时 品色线 变成绿色 当它 越过 下降时 变成红色 ......谢谢。)
 
bilbao:

嗨,Mladen先生

请为其制作MTF

注意

这里是多时间框架版本

附加的文件:
 
你好,Mladen,你过去曾帮助我修改过一些指标,我非常感谢你的努力。我希望你能对这个指标有所帮助。它是一个蜡烛时间指标,但独立于点位,并且可以选择自己喜欢的时间段进行监控。这就是我喜欢这个指标的原因。我对它的唯一问题是,当我把它加载到图表上时,它出现在图表的中间,所以有时我很难正确看到它,因为价格蜡烛的移动。我希望你能修改它,使其有选项,使其出现在图表的 任何角落 的右边。我把指标附在图片上说明我的意思。
附加的文件:
 
baraozemo:

嗨,mladen。

这里是样本-ea

姆拉登。
尾随步骤买入卖出 操作的作用是一样的......。
它是用尾随步骤移动 "止损"。

比如说(买入例子)


EA Input:
=========
TakeProfit      =22000 (22 points)
Trailing_Distance=4000 (4 points)
Trailing_Step    =2000 (2 points)
StopLoss         =8000 (8 points)

 

====operation entry
buy at price   3440.00  
stoploss      =3432.00 (entrance -8 points)
takeprofit    =3462.00 (entrance +22 points)
-------

price reached       =3444.00    (=4 points)
trailing distance reached   (4000=4 points) 
then move stoploss using 'step' (2000= 2 points)
new stoploss now is =3434.00    (=+2 points from step)

------- 

price reached       =3448.00    (=+4 points)
trailing distance reached (4000=4 points) 
then move stoploss using 'step' (2000= 2 points)
new stoploss now is =3436.00    (=+2 points from step)

-------

price grown up to   =3452.00    (=+4 points)
trailing distance reached (4000=4 points) 
then move stoploss using 'step' (2000= 2 points)
new stoploss now is =3438.00    (=+2 points from step)

-------

 

when is a "buy" operation , step (increase the stoploss price)
when is a "sell" operation, step (decrease the stoploss price)

 

嗨,Mladen先生。

你能不能为这个有用的指标 做一个简单的柱状图?

注意

附加的文件:
 
mladen:

这里是多时间框架版本

非常感谢先生
 

亲爱的Mladen,

我需要你帮助检查 使用SmStrengthRange 09_v2.4指标的代码EA

在货币对交叉后,例如EURUSD
(EUR交叉到USD上方),然后第一个发散绿点出现=买入
(EUR交叉到USD下方),然后第一个发散红点出现=卖出

我刚刚自己试了一下,但是不能工作
请检查这个代码并纠正

// 指标调用

double USD=iCustom(NULL,0, "smStrengthRange09_v2.4",3,shift);
double USD1=iCustom(NULL,0, "smStrengthRange09_v2.4",3,shift+1);
double EUR=iCustom(NULL,0, "smStrengthRange09_v2.4",4,shift);
double EUR1=iCustom(NULL,0, "smStrengthRange09_v2.4",4,shift+1);
double GBP=iCustom(NULL,0, "smStrengthRange09_v2.4",5,shift);
double GBP1=iCustom(NULL,0, "smStrengthRange09_v2.4",5,shift+1);
double CHF=iCustom(NULL,0, "smStrengthRange09_v2.4",6,shift);
double CHF1=iCustom(NULL,0, "smStrengthRange09_v2.4",6,shift+1);
double JPY=iCustom(NULL,0, "smStrengthRange09_v2.4",7,shift);
double JPY1=iCustom(NULL,0, "smStrengthRange09_v2.4",7,shift+1);
double AUD=iCustom(NULL,0, "smStrengthRange09_v2.4",8,shift);
double AUD1=iCustom(NULL,0, "smStrengthRange09_v2.4",8,shift+1);
double CAD=iCustom(NULL,0, "smStrengthRange09_v2.4",9,shift);
double CAD1=iCustom(NULL,0, "smStrengthRange09_v2.4",9,shift+1);
double NZD=iCustom(NULL,0, "smStrengthRange09_v2.4",10,shift);
double NZD1=iCustom(NULL,0, "smStrengthRange09_v2.4",10,shift+1);

double green=iCustom(NULL,0, "smStrengthRange09_v2.4",11,shift);
double greena=iCustom(NULL,0, "smStrengthRange09_v2.4",11,shift+1);
double red=iCustom(NULL,0, "smStrengthRange09_v2.4",12,shift);
double reda=iCustom(NULL,0, "smStrengthRange09_v2.4",12,shift+1);

//进入信号

if ((green!=EMPTY_VALUE && !(greena!=EMPTY_VALUE && EUR>USD)) signal1=1;

if((red!=EMPTY_VALUE && !(reda!=EMPTY_VALUE && EUR<USD)) signal2=2;


请帮助查看这段代码并加以纠正


谢谢你,问候你

附加的文件:
 
basheer1966:

亲爱的Mladen,

我需要你帮助检查使用SmStrengthRange 09_v2.4指标的代码EA

在货币对交叉后,例如EURUSD
(EUR交叉到USD上方),然后第一个发散绿点出现=买入
(EUR交叉到USD下方),然后第一个发散红点出现=卖出

我刚刚自己试了一下,但是不能工作
请检查这个代码并纠正

// 指标调用

double USD=iCustom(NULL,0, "smStrengthRange09_v2.4",3,shift);
double USD1=iCustom(NULL,0, "smStrengthRange09_v2.4",3,shift+1);
double EUR=iCustom(NULL,0, "smStrengthRange09_v2.4",4,shift);
double EUR1=iCustom(NULL,0, "smStrengthRange09_v2.4",4,shift+1);
double GBP=iCustom(NULL,0, "smStrengthRange09_v2.4",5,shift);
double GBP1=iCustom(NULL,0, "smStrengthRange09_v2.4",5,shift+1);
double CHF=iCustom(NULL,0, "smStrengthRange09_v2.4",6,shift);
double CHF1=iCustom(NULL,0, "smStrengthRange09_v2.4",6,shift+1);
double JPY=iCustom(NULL,0, "smStrengthRange09_v2.4",7,shift);
double JPY1=iCustom(NULL,0, "smStrengthRange09_v2.4",7,shift+1);
double AUD=iCustom(NULL,0, "smStrengthRange09_v2.4",8,shift);
double AUD1=iCustom(NULL,0, "smStrengthRange09_v2.4",8,shift+1);
double CAD=iCustom(NULL,0, "smStrengthRange09_v2.4",9,shift);
double CAD1=iCustom(NULL,0, "smStrengthRange09_v2.4",9,shift+1);
double NZD=iCustom(NULL,0, "smStrengthRange09_v2.4",10,shift);
double NZD1=iCustom(NULL,0, "smStrengthRange09_v2.4",10,shift+1);

double green=iCustom(NULL,0, "smStrengthRange09_v2.4",11,shift);
double greena=iCustom(NULL,0, "smStrengthRange09_v2.4",11,shift+1);
double red=iCustom(NULL,0, "smStrengthRange09_v2.4",12,shift);
double reda=iCustom(NULL,0, "smStrengthRange09_v2.4",12,shift+1);

//进入信号

if ((green!=EMPTY_VALUE && !(greena!=EMPTY_VALUE && EUR>USD)) signal1=1;

if((red!=EMPTY_VALUE && !(reda!=EMPTY_VALUE && EUR<USD)) signal2=2;


请帮助查看这段代码并加以纠正


谢谢和问候

你不是在检查 交叉点。你只是在检查某个值是否大于或小于另一个值。

对于交叉盘,你必须至少检查2个缓冲区的2个值(4个值要检查)。

 

Hi Pro-Codeers,

我想实现一个Bool RSI过滤器,可以打开或关闭。

这个程序可以/应该被优化吗?

extern bool RSI_on = true;

   if(RSI_on=true)

     {
      if(trendNow!=trendPrev)
        {
         if(trendNow>0 && (NLD1>NLD2) && RSIfilter>51)
           {
            OpenBuy_  =true;
            CloseSell_=true;
           }
         else
         if(trendPrev>0 && (NLD1<NLD2) && RSIfilter<49)
           {
            OpenSell_=true;
            CloseBuy_=true;
           }
        }
     }
else
     if(trendNow!=trendPrev)
     {
      if(trendNow>0 && (NLD1>NLD2))
        {
         OpenBuy_  =true;
         CloseSell_=true;
        }
      else
      if(trendPrev>0 && (NLD1<NLD2))
        {
         OpenSell_=true;
         CloseBuy_=true;
        }
     }
 
tfi_markets:

Hi Pro-Codeers,

我想实现一个Bool RSI过滤器,可以打开或关闭。

这个程序可以/应该被优化吗?

extern bool RSI_on = true;

   if(RSI_on=true)

     {
      if(trendNow!=trendPrev)
        {
         if(trendNow>0 && (NLD1>NLD2) && RSIfilter>51)
           {
            OpenBuy_  =true;
            CloseSell_=true;
           }
         else
         if(trendPrev>0 && (NLD1<NLD2) && RSIfilter<49)
           {
            OpenSell_=true;
            CloseBuy_=true;
           }
        }
     }
else
     if(trendNow!=trendPrev)
     {
      if(trendNow>0 && (NLD1>NLD2))
        {
         OpenBuy_  =true;
         CloseSell_=true;
        }
      else
      if(trendPrev>0 && (NLD1<NLD2))
        {
         OpenSell_=true;
         CloseBuy_=true;
        }
     }

试着这样做(这应该是整个代码替换了上面的代码)。

      if(trendNow!=trendPrev)
         if(trendNow>0 && (NLD1>NLD2) && (!RSI_on || (RSI_on && RSIfilter>51)))
           {
            OpenBuy_  =true;
            CloseSell_=true;
           }
         else
         if(trendPrev>0 && (NLD1<NLD2) && (!RSI_on || (RSI_on && RSIfilter<49)))
           {
            OpenSell_=true;
            CloseBuy_=true;
           }