编写要求:
解答:
?网友求助:
第一个公式:
REFLINE:0;
DIFF:=EMA(CLOSE,3)-EMA(CLOSE,8);
DEA:=EMA(DIFF,5);
MACD := 2*(DIFF-DEA);
X1:=EMA(DIFF,5)*5;
X2:=((EMA(CLOSE,3)-EMA(CLOSE,8)))*5;
X3:IF(X2>0,X2,0),POINTDOT,COLORRED;
X4:=IF(X2<0,X2,0),POINTDOT,COLORGREEN;
STICKLINE(X2>0,0,X2,2.8,0),COLORRED;
STICKLINE(X2>0,0,X2,2.8,0),COLOR000088;
STICKLINE(X2>0,0,X2,2.6,0),COLOR000099;
STICKLINE(X2>0,0,X2,2.4,0),COLOR0000AA;
STICKLINE(X2>0,0,X2,2.2,0),COLOR0000BB;
STICKLINE(X2>0,0,X2,2,0),COLOR0000CC;
STICKLINE(X2>0,0,X2,1.8,0),COLOR0000DD;
STICKLINE(X2>0,0,X2,1.5,0),COLOR0000EE;
STICKLINE(X2>0,0,X2,1.0,0),COLOR0000FF;
STICKLINE(X2>0,0,X2,0.0,0),COLOR0000FF;
STICKLINE(X2<0,0,X2,2.8,0),COLORGREEN;
STICKLINE(X2<0,0,X2,2.8,0),COLOR007700;
STICKLINE(X2<0,0,X2,2.6,0),COLOR008800;
STICKLINE(X2<0,0,X2,2.6,0),COLOR009900;
STICKLINE(X2<0,0,X2,2.4,0),COLOR00BB00;
STICKLINE(X2<0,0,X2,2.0,0),COLOR00CC00;
STICKLINE(X2<0,0,X2,1.8,0),COLOR00DD00;
STICKLINE(X2<0,0,X2,1.5,0),COLOR00EE00;
STICKLINE(X2<0,0,X2,1,0),COLOR00FF00;
STICKLINE(X2<0,0,X2,0,0),COLOR00FF00;
资金动能A:X2,COLORWHITE,LINETHICK2;
资金动能B:X1,COLORBROWN,LINETHICK3;
VAR2:=(CLOSE-LLV(LOW,26))/(HHV(HIGH,26)-LLV(LOW,26))*100;
VAR3:=SMA(SMA(VAR2,3,1),3,1);
VAR4:=EMA(VAR3,5);
大底部:IF(CROSS(VAR4,10) AND VAR4>10,14,0);
中底部:IF(CROSS(VAR4,20) AND VAR4>10,13,0);
小底部:IF(CROSS(VAR4,30) AND VAR4>10,12,0);
AA:=VOL>=REF(V,1)*1.91 AND C>REF(C,1)*1.01;
红柱:DRAWICON(CROSS(资金动能A,0) AND AA,-1,1);
持币:IF(SAR(10,2,20)>=H,0,DRAWNULL),CIRCLEDOT,COLORWHITE;
持股:IF(SAR(10,2,20)<=L,0,DRAWNULL),CROSSDOT,LINETHICK3,COLORYELLOW;
个股:=EMA(100*(C-LLV(LOW,34))/(HHV(H,34)-LLV(LOW,34)),3),COLOR1010FF;
短线反弹:IF(CROSS(个股,9),10,0),STICK,LINETHICK3,COLOR00FF00;
A7:=C-REF(C,1);
A8:=100*EMA(EMA(A7,6),6)/EMA(EMA(ABS(A7),6),6);
SHORT:=7; LONG:=19;
RMA:=EMA(CLOSE,SHORT);
NMA:=EMA(CLOSE,LONG);
第二个公式:
VAR1:=(HIGH+LOW+OPEN+CLOSE*2)/5;
VAR2:=EMA(VAR1,21);
VAR3:=STD(VAR1,23);
VAR4:=EMA(VAR1,2);
VARA:=(VAR1-VAR2)*100/VAR3;
K:(EMA(VARA,23)+100)/2-3,LINETHICK2,COLORFF0000;
D:SMA(K,5,1),LINETHICK2,COLORFFFF00;
J:4*K-3*D,LINETHICK2,COLORFF00FF;
DRAWICON(FILTER(J>REF(J,1) AND JREF(VAR4,1)
AND K>=REF(K,1) AND J<40 OR CROSS(J,K) AND CROSS(J,D) AND J<40 OR J>REF
(J,1) AND J<-20,7),J*0.8,6);
DRAWICON(FILTER(J<=REF(J,1) AND J>80,8),J*1.2,5);
AA:=CROSS(J,D);
DRAWICON(AA,LOW,1);
VAR1M:=REF(CLOSE,1);
VAR2M:=(SMA(MAX(CLOSE-VAR1M,0),6,1))/(SMA(ABS(CLOSE-VAR1M),6,1))*100;
短期顶部:CROSS(80,VAR2M)*100,COLORFF0000;
DRAWTEXT(CROSS(80,VAR2M),100,'★顶'),COLORFFFF00;
VAR3M:=(SMA(MAX(CLOSE-VAR1M,0),7,1))/(SMA(ABS(CLOSE-VAR1M),7,1))*100;
VAR4M:=(SMA(MAX(CLOSE-VAR1M,0),13,1))/(SMA(ABS(CLOSE-VAR1M),13,1))*100;
VAR5M:=BARSCOUNT(CLOSE);
短期底部:=VAR3M<20 AND VAR4M<25 AND VAR5M>50*100;
DRAWTEXT(CROSS(100,短期底部),100,'短 '),COLORFFFF00;
AM:=IF(DATE<=1091231,1,0);
AAM:=CLOSE/REF(CLOSE,1)>=1.099;
AB:=VOL/REF(VOL,1);
涨停预警:IF(CLOSE/REF(CLOSE,1)>=1.03 AND AB<1,33,0),COLORFF0000;
目标出现:(IF(AAM AND AB<1,55,0))*AM,LINETHICK2,COLORFFFF00;
?
Copyright 2018- www.dyjian.com/ 大宇股票知识网 海口美兰韩哲棚百货商行 版权所有 琼ICP备2023001966号
免责声名:本站所发表的内容仅用于学术交流和学习,内容所带来的一切后果均与本站无关。若您发现本站存在您非授权的原创作品,请第一时间联系本站删除!