急!请高手帮忙写一个通信达的MACD指标公式。要求见问题补充,谢谢!

当DIF>0时,若当天DIF值大于前一天的值,DIF线画红线;
若当天DIF值小于前一天的值,DIF线画绿线,且写上前一天的DIF值。
当DIF<0时,若当天DIF值小于前一天的值,DIF线画绿线;
若当天DIF值大于前一天的值,DIF线画红线,且写上前一天的DIF值。
等了1个小时咯,还没有朋友帮忙解决下啊,急啊!!!

我十分同意你所说的“真正的高手不需要指标. ”,不过真正的高手也亦是寥寥无几,并不是谁都能当所谓真正的高手。所以我还是要帮楼主写一个通信达的MACD指标公式,完全按照原要求!公式如下:
DIFF : (EMA(CLOSE,12) - EMA(CLOSE,26))/EMA(C,512)*2000,NODRAW;
DEA : EMA(DIFF,9),NODRAW;
DRAWBAND(DIFF,RGB(120,00,00),DEA,RGB(00,80,00));
MACD : 2*(DIFF-DEA), COLORSTICK;
DRAWBAND(0,RGB(100,100,100),0,0);
X00:=C;
X01:=0.7522406533*X00+0.3609454219*REF(X00,1)-0.03309329629*REF(X00,2)-0.04241822779*REF(X00,3)-0.026737249*REF(X00,4)-0.007010041271*REF(X00,5)-0.002652859952*REF(X00,6)-0.0008415042966*REF(X00,7)-0.0002891931964*REF(X00,8)-0.0000956265934*REF(X00,9)-0.0000321286052*REF(X00,10)-0.0000106773454*REF(X00,11)-0.0000035457562*REF(X00,12)-0.0000011670713*REF(X00,13);
X02:=0.7522406533*X01+0.3609454219*REF(X01,1)-0.03309329629*REF(X01,2)-0.04241822779*REF(X01,3)-0.026737249*REF(X01,4)-0.007010041271*REF(X01,5)-0.002652859952*REF(X01,6)-0.0008415042966*REF(X01,7)-0.0002891931964*REF(X01,8)-0.0000956265934*REF(X01,9)-0.0000321286052*REF(X01,10)-0.0000106773454*REF(X01,11)-0.0000035457562*REF(X01,12)-0.0000011670713*REF(X01,13);
X03:=0.7522406533*X02+0.3609454219*REF(X02,1)-0.03309329629*REF(X02,2)-0.04241822779*REF(X02,3)-0.026737249*REF(X02,4)-0.007010041271*REF(X02,5)-0.002652859952*REF(X02,6)-0.0008415042966*REF(X02,7)-0.0002891931964*REF(X02,8)-0.0000956265934*REF(X02,9)-0.0000321286052*REF(X02,10)-0.0000106773454*REF(X02,11)-0.0000035457562*REF(X02,12)-0.0000011670713*REF(X02,13);

WA4:=EMA(EMA(EMA((EMA(X01,1)+EMA(X01,2)+EMA(X01,3)+EMA(X01,4))/4,2),2),2);
WA5:=EMA(WA4,2);
WA6:=EMA(WA5,2);
WA7:=EMA(WA6,2);
BB1:=(X00+X01+X02+X03)/4;
BB2:=(WA5+WA6+WA7)/3;

WA13:=EMA((((EMA(X01,32)+EMA(X01,33))+EMA(X01,34))/3),2);
WA8:=EMA((((EMA(X01,22)+EMA(X01,23))+EMA(X01,24))/3),2);
WA9:=EMA((((EMA(X01,24)+EMA(X01,25))+EMA(X01,26))/3),2);
WA10:=EMA((((EMA(X01,26)+EMA(X01,27))+EMA(X01,28))/3),2);
WA11:=EMA((((EMA(X01,28)+EMA(X01,29))+EMA(X01,30))/3),2);
WA12:=EMA((((EMA(X01,30)+EMA(X01,31))+EMA(X01,32))/3),2);
BB:=(WA13+WA8+WA9+WA10+WA11+WA12)/6;
~DIF:(BB1-BB)/BB*1000,COLORWHITE;
~DEAL:(BB2-BB)/BB*1000,COLORYELLOW,LINETHICK1;{原文链接:http://www.55188.com/thread-4960869-1-1.html}
温馨提示:内容为网友见解,仅供参考
第1个回答  2012-10-17
DIF:MACD.DIF,COLOR33FF33,LINETHICK1;
DEA:MACD.DEA;
MACD:MACD.MACD,COLORSTICK;
IF(DIF>=REF(DIF,1) ,DIF,DRAWNULL),COLORRED;
IF(DIF>=REF(DIF,1) AND DIF<=0,DIF,DRAWNULL),COLORRED;
DRAWNUMBER(DIF<=REF(DIF,1) AND REF(DIF,1)>=REF(DIF,2) AND DIF>=0,REF(DIF,1)*1.1,REF(DIF,1));
DRAWNUMBER(DIF>=REF(DIF,1) AND REF(DIF,1)<=REF(DIF,2) AND DIF<=0,REF(DIF,1)*0.9,REF(DIF,1));

说明:鉴于通达信画线公式功能的局限性,短暂一天的dif拐头是无法变色的,但是可以标出dif数值。追问

我已将DRAWNUMBER修改为DRAWTEXT,测试能通过,但是调用该指标时,软件会报错提示为“对 一未命名文件 进行查找失败”。
以上请帮忙解决,非常感谢!

追答

这个不是公式的问题,是软件的问题。换个软件试试。

本回答被提问者采纳
第2个回答  2012-10-16
真正的高手不需要指标.追问

我需要这个指标参考,不是靠这个指标来吃饭啦。(我也知道指标庄家可以制作出来形成骗线的)

急!请高手帮忙写一个通信达的MACD指标公式。要求见问题补充,谢谢!
MACD : 2*(DIFF-DEA), COLORSTICK;DRAWBAND(0,RGB(100,100,100),0,0);X00:=C;X01:=0.7522406533*X00+0.3609454219*REF(X00,1)-0.03309329629*REF(X00,2)-0.04241822779*REF(X00,3)-0.026737249*REF(X00,4)-0.007010041271*REF(X00,5)-0.002652859952*REF(X00,6)-0.0008415042966*REF...

求这个MACD指标公式。要求通达信的!!
<<自用MACD指标公式>> DIF:EMA(CLOSE,5)-EMA(CLOSE,10);DEA:EMA(DIF,5);MACD:(DIF),COLORSTICK;DIF,COLORGREEN,LINETHICK2;DEA,COLORGREEN,LINETHICK2;零上金叉买:0,COLORGREEN,LINETHICK2;IF(DIF>DEA,DIF,DRAWNULL),COLORRED,LINETHICK2;IF(DEA>REF(DEA,1),DEA,DRAWNULL),COLORMAGENTA,LINETHIC...

请高手帮忙写个通达信MACD在零轴之上形成金叉的选股公式,万分感谢...
DIF:=EMA(CLOSE,12)-EMA(CLOSE,26); DEA:=EMA(DIF,9); MACD:=(DIF-DEA)*2; 距离范围:=RANGE(DEA,-0.2,0.2); {调整值:-0.2,0.2,扩大或缩小范围} XG:CROSS(DIF,DEA) AND 距离范围; DIF:=EMA(CLOSE,12)-EMA(CLOSE,26) DEA:=EMA(DIF,9);MACD:=(DIF-DEA)*2...

请高手帮忙做个通达信macd,dea和dif都是上涨的公式,谢谢谢谢。
DIF:=EMA(CLOSE,12)-EMA(CLOSE,26);DEA:=EMA(DIF,9);MACD:=(DIF-DEA)*2,;xg:dif>ref(dif,1) and dea>ref(dea,1)

哪位老师有通达信MACD柱体背离的指标公式分享一个,真心感谢
DIFF := EMA(CLOSE,12) - EMA(CLOSE,26);DEA : =EMA(DIFF,9);MACD : =2*(DIFF-DEA);DD:=C=HHV(C,180);EE:=DEA< REF(DEA,1) AND REF(DEA< REF(DEA,1),1)=1;CC:=C> REF(C,1) AND REF(C> REF(C,1),1)=1;FF:=C=LLV(C,180);GG:= DEA> REF(DEA,1) AND REF...

求通达信公式:macd选股公式
DIF:=EMA(CLOSE,12)-EMA(CLOSE,26);DEA:=EMA(DIF,9);MACD:=(DIF-DEA)*2;X1:DIF>REF(DIF,1) AND V>=MA(V,50),COLORRED;X2:MACD<REF(MACD,1),COLORGREEN;这样的条件设计会信号过多,而且,出现两条件重叠情况.

求高手编写一个通达信MACD指标公式,要把每一小段的面积用数字表示出来...
用别人的 送你个自写的缠中说禅的macd指标 我编制的通达信公式是这样的:参数:short 默认是12,范围你自己定(下同)long默认是26;mid默认是9;K默认是0,范围0-1,0是显示均线面积,1是显示macd面积 MA1:=MA(CLOSE,5);MA2:=MA(CLOSE,10);DIF:=EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);DEA:...

通达信MACD公式,请高手请把下面指标公式里的金叉死叉+个箭头表示...
MACD:2*(DIFF-DEA), COLORSTICK,LINETHICK2;低位金叉:=CROSS(DIFF,DEA) AND DIFF<-0.1;STICKLINE(低位金叉,0,0.08,6,0),COLORYELLOW;JCCOUNT:=COUNT(CROSS(DIFF,DEA),BARSLAST(DEA>=0));二次金叉:=CROSS(DIFF,DEA) AND DEA<0 AND COUNT(JCCOUNT=2,21)=1;STICKLINE(二次金叉,0,0.06,6...

求高手编一个通达信MACD底背离的公式
MACD底背:IF(B1>0,-0.1,0),COLORRED,POINTDOT;KDJ底背:IF(B2>0,-0.1,0),COLORFF00FF,POINTDOT;RSI底背:IF(B3>0,-0.1,0),COLORYELLOW,POINTDOT;MACD顶背:IF(D1>0,0.1,0),COLOR00FF00,POINTDOT;KDJ顶背:IF(D2>0,0.1,0),COLORFFCC66,POINTDOT;RSI顶背:IF(D3>0,0.1...

老师你好 帮我编一个通达信MACD 0轴上面(第一根)红柱选股公式
DIF:=EMA(CLOSE,12)-EMA(CLOSE,26);DEA:=EMA(DIF,9);MACD:=(DIF-DEA)*2;卖出:CROSS(MACD,0);

相似回答