六六公式网

 找回密码
 立即注册
微信扫一扫 分享朋友圈

已有 4179 人浏览分享

开启左侧

通达信手机公式MACD主升浪和彩带买点

[复制链接]
4179 8
手机 Android V3.11以上版本,分时图/多日分时图指标支持全部系统指标和用户指标,下面发两个用户指标,先看明泰铝业(601677)图示:
Screenshot_2017-08-14-23-15-54.png

MACD主升浪源代码:
DIF1:=EMA(CLOSE,12)-EMA(CLOSE,26),COLOR00FF00,LINETHICK1;
DEA1:=EMA(DIF1,9),COLOR00FF00,LINETHICK1;
DRAWICON(CROSS(DIF1,DEA1),DEA1,1);
DRAWICON(CROSS(DEA1,DIF1),DEA1,2);
{主升浪消失出局}
DI:=EMA(CLOSE,4)-EMA(CLOSE,13),COLORMAGENTA,LINETHICK2;
D1:=EMA(DI,5),COLORGRAY;
D2:=EMA(DI,10),COLORGRAY;
D3:=EMA(DI,20),COLORGRAY;
D4:=EMA(DI,30),COLORGRAY;
D5:=EMA(DI,60),COLORGRAY;
D6:=EMA(DI,90),COLORGRAY;
D7:=EMA(DI,120),COLORGRAY;
D8:=EMA(DI,250),COLORGRAY;
AA:=STICKLINE(DI>=REF(DI,1) AND D1>=REF(D1,1) AND D2>=REF(D2,1) AND D3>=REF(D3,1) AND D4>=REF(D4,1) AND D5>=REF(D5,1) AND D6>=REF(D6,1) AND D7>=REF(D7,1) AND D8>=REF(D8,1) AND C>EMA(C,11) AND DI>-0.8,DI,0,2,0),COLORRED;
STICKLINE(AA,DIF1,DEA1,3,0),COLORE6E8FA;
{柱状线}
MACD1:=(DIF1-DEA1)*2;
STICKLINE(MACD1>REF(MACD1,1),0,MACD1,3.2,0),COLOR0000FF;
STICKLINE(MACD1>REF(MACD1,1),0,MACD1,2.7,0),,COLOR0000FF;
STICKLINE(MACD1>REF(MACD1,1),0,MACD1,2.1,0),COLOR0000FF;
STICKLINE(MACD1>REF(MACD1,1),0,MACD1,1.5,0),COLOR0000FF;
STICKLINE(MACD1>REF(MACD1,1),0,MACD1,0.9,0),COLOR0000FF;
STICKLINE(MACD1>REF(MACD1,1),0,MACD1,0.3,0),COLORCC66FF;
STICKLINE(MACD1<REF(MACD1,1),0,MACD1,3.2,0),COLORFF9900;
STICKLINE(MACD1<REF(MACD1,1),0,MACD1,2.7,0),COLORFF9900;
STICKLINE(MACD1<REF(MACD1,1),0,MACD1,2.1,0),COLORFF9900;
STICKLINE(MACD1<REF(MACD1,1),0,MACD1,1.5,0),COLORFF9900;
STICKLINE(MACD1<REF(MACD1,1),0,MACD1,0.9,0),COLORFF9900;
STICKLINE(MACD1<REF(MACD1,1),0,MACD1,0.3,0),COLORFFCC00;
STICKLINE(MACD1>=0 OR MACD1<=0,0,0,50,1),COLORWHITE;
{买点提示}
A1:=BARSLAST(REF(CROSS(DIF1,DEA1),1));
BL:=REF(CLOSE,A1+1)>CLOSE AND DIF1>REF(DIF1,A1+1) AND CROSS(DIF1,DEA1);
{STICKLINE(BL,0,1,2,0),COLOR00FF00;}
DRAWICON(BL,DEA1,23);
A2:=BARSLAST(REF(CROSS(DEA1,DIF1),1));
DBL:=REF(CLOSE,A2+1)<CLOSE AND REF(DIF1,A2+1)>DIF1 AND CROSS(DEA1,DIF1);
DRAWICON(DBL,DEA1,12);
低位金叉:=CROSS(DIF1,DEA1) AND DIF1<-0.1;
DRAWTEXT(低位金叉,DIF1,' 低位金叉');
JCCOUNT:=COUNT(CROSS(DIF1,DEA1),BARSLAST(DEA1>=0));
二次金叉:=CROSS(DIF1,DEA1) AND DEA1<0 AND COUNT(JCCOUNT=2,21)=1;
DRAWICON(二次金叉,DEA1*1.04,13) ;
DRAWTEXT(二次金叉,-0.1,' 二次金叉'),COLORFF00FF;
A10:=BARSLAST(REF(CROSS(DIF1,DEA1),1));
底背离:=REF(CLOSE,A10+1)>CLOSE AND DIF1>REF(DIF1,A10+1) AND CROSS(DIF1,DEA1);
DRAWLINE(A10=0,DEA1,底背离,DEA1,0),COLORRED,LINETHICK2;
DRAWTEXT(底背离,-0.50,' 底背离'),COLOR00FF00;
A20:=BARSLAST(REF(CROSS(DEA1,DIF1),1));
顶背离:=REF(CLOSE,A20+1)<CLOSE AND REF(DIF1,A20+1)>DIF1 AND CROSS(DEA1,DIF1);
DRAWLINE(A20=0,DEA1,顶背离,DEA1,0),COLORWHITE,LINETHICK2;
{趋势柱状线}
WY1001:=(2*CLOSE+HIGH+LOW)/4;
WY1002:=EMA(WY1001,4);
WY1003:=EMA(WY1002,4);
WY1004:=EMA(WY1003,4);
X:=(WY1004-REF(WY1004,1))/REF(WY1004,1)*100;
X1:=IF(X<REF(X,1),X,DRAWNULL),COLORWHITE,LINETHICK2;
XO:=MA(X,2),COLOR9932CD;
SI:=REF(X,1);
STICKLINE(X>SI,X,SI,2.3,0),COLOR0000FF;
STICKLINE(X>SI,X,SI,0.3,0),COLORCC66FF;
STICKLINE(X<SI,X,SI,2.3,0),COLOR00BB00;
STICKLINE(X<SI,X,SI,0.3,0),COLOR00FF00;
STICKLINE(底背离,X,SI,1,0),COLORYELLOW;
STICKLINE(低位金叉,X,SI,1,0),COLORWHITE;
STICKLINE(低位金叉 AND 底背离,X,SI,0.1,0),COLORYELLOW;
{买点2,可省}
VAR2:=REF(LOW,1);
VAR3:=SMA(ABS(LOW-VAR2),3,1)/SMA(MAX(LOW-VAR2,0),3,1)*100;
VAR4:=EMA(IF(CLOSE*1.3,VAR3*10,VAR3/10),3);
VAR5:=LLV(LOW,13);
VAR6:=HHV(VAR4,13);
VAR7:=IF(MA(CLOSE,34),1,0);
VAR8:=EMA(IF(LOW<=VAR5,(VAR4+VAR6*2)/2,0),3)/618*VAR7;
VAR9:=IF(VAR8>100,100,VAR8);
VAR10:=IF(VAR9>-120,VAR9,0);
VAR11:=VAR10<REF(VAR10,1);
DRAWTEXT(VAR11 AND REF(NOT(VAR11),1),0,'☆'),COLORYELLOW;
{走势线}
DIF:DIF1,LINETHICK1,COLORGREEN;
DEA:DEA1,LINETHICK1,COLORGREEN;
DIF2:IF(MACD>REF(MACD,1),DIF1,DRAWNULL),COLORRED,LINETHICK1;
DEA2:IF(DEA1<DIF1,DEA1,DRAWNULL),COLORFF00FF,LINETHICK1;
{主力进场}
VAR12:=REF((LOW+OPEN+CLOSE+HIGH)/4,1);
VAR13:=SMA(ABS(LOW-VAR12),13,1)/SMA(MAX(LOW-VAR12,0),10,1);
VAR14:=EMA(VAR13,10);
VAR15:=LLV(LOW,33);
VAR16:=EMA(IF(LOW<=VAR15,VAR14,0),3);
主力进场:=IF(VAR16>REF(VAR16,1),VAR16,0),COLORRED,NODRAW;
STICKLINE(主力进场,X,SI,0.1,0),COLORRED;





彩带买点源代码:
N:=13;M:=3;P:=34;
PSY:COUNT(CLOSE>REF(CLOSE,1),N)/N*100,COLOR00FFFF;
PA:MA(PSY,M),COLOR0000FF;
PAP:MA(PSY,P),COLOR00FFFF,LINETHICK1;
DRAWBAND(PSY,RGB(200,0,0),PA,RGB(0,100,50));
TJ11:=CROSS(PSY,PA) AND PA<16;
TJ12:=CROSS(PSY,PA) AND PA<10;
TJ1:=TJ11 OR TJ12;
TJ10:=FILTER(TJ1,8);
TJ2:=LONGCROSS(PA,PAP,21);
DRAWICON(TJ10,PA,25);
DRAWICON(TJ2,PAP,23);
SL1:=CROSS(PA,PSY) AND PA>70;
SL2:=CROSS(80,PA);
SL:=FILTER(SL1 OR SL2,5);
DRAWICON(SL,PA,19);
V1:=(C+H+L)/3;
MA3:=MA(V1,5);
MA5:=MA(V1,13);
N1:=BARSLAST(CROSS(MA3,MA5));
N2:=BARSLAST(CROSS(MA5,MA3));
N8:=IF(N1<N2,N1+1,0-N2-1);
STICKLINE(N8>0,0,2,3,0),COLOR0000FF;
STICKLINE(N8<0,0,2,3,0),COLOR00FF00;
JJ:=DYNAINFO(11);
TJ4:=FILTER((C-JJ)/JJ<-0.02 AND PA<16,13);
STICKLINE(TJ4,20,0,6,0),COLOR00FFFF;
TJ5:=FILTER((C-JJ)/JJ<-0.04 AND PA<16,13);
STICKLINE(TJ5,20,0,6,0),COLOR0000FF;
TJ6:=FILTER((C-JJ)/JJ>0.02 AND PA>60,13);
STICKLINE(TJ6,80,60,6,0),COLORFF0000;
TJ7:=FILTER((C-JJ)/JJ>0.05 AND PA>60,13);
STICKLINE(TJ7,80,60,6,0),COLOR00FF00;
DRAWTEXT(TJ4 OR TJ5 ,20,'买'),COLORFF00FF;
DRAWTEXT(TJ6 OR TJ7 ,60,'卖'),COLOR00FF00;

[

举报 使用道具

回复

评论 8

黄三  资深股民  发表于 2018-8-26 13:01:41 | 显示全部楼层
楼主辛苦了,感谢分享!

举报 使用道具

回复 支持 反对
好运已来  初级股民  发表于 2018-3-15 17:14:22 | 显示全部楼层
用不了的,

举报 使用道具

回复
平面湖水  中级大户  发表于 2017-10-31 10:11:44 | 显示全部楼层
谢谢楼主无私分享

举报 使用道具

回复 支持 反对
手放开  论坛游民  发表于 2017-10-31 07:57:23 | 显示全部楼层
谢谢楼主无私分享

举报 使用道具

回复 支持 反对
平面湖水  中级大户  发表于 2017-10-28 17:53:26 | 显示全部楼层
谢谢楼主分享!

举报 使用道具

回复 支持 反对
清新禾卫  中级股民  发表于 2017-9-20 13:58:58 | 显示全部楼层
受人以鱼、不如授人以渔,楼主大公无私精神,值得敬佩学习,祝投资顺利!

举报 使用道具

回复 支持 反对
搞笑的干脆面  论坛游民  发表于 2017-8-17 09:10:07 | 显示全部楼层
这指标是楼主编的吗?

举报 使用道具

回复 支持 反对
流云  初级股民  发表于 2017-8-15 02:41:06 | 显示全部楼层
感谢分享,多谢

举报 使用道具

回复 支持 反对

2

关注

7

粉丝

372

主题
随机推荐
热门指标
精品推送
精品指标

QQ|Archiver|小黑屋|六六公式网

GMT+8, 2024-11-24 05:48 , Processed in 0.179671 second(s), 33 queries .

Powered by Discuz! X3.4

Copyright © 2001-2020, Tencent Cloud.