日天A2主图指标公式源码[通达信公式]
DIFF:=EMA(C,12) - EMA(C,26);
DEA:=EMA(DIFF,9);
RSV:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9));
K:=SMA(RSV,9,3);
D:=SMA(K,9,3);
J:=3*K-2*D;
A:=CROSS(DIFF,DEA) AND CROSS(K,D) AND CROSS(J,D) AND DIFF<0;
A7:=FILTER(A,20);
DRAWTEXT(A7,L*0.999,'↑金振'),COLOR0000FF;
SA:=CROSS(DEA,DIFF) AND CROSS(D,K) AND CROSS(D,J) AND DIFF>0;
A8:=FILTER(SA,20);
DRAWTEXT(A8,H,'↓死振'),COLORWHITE;
{程序化久久公式网WWW.CXH99.COM}G1:=DIFF>REF(DIFF,1) AND DEA>REF(DEA,1);
G2:=DIFF<REF(DIFF,1)AND DEA<REF(DEA,1);
RSV1:=(C-LLV(L,27))/(HHV(H,27)-LLV(L,27))*100;
K1:=SMA(RSV1,5,1);
E1:=SMA(K1,3,1);
J1:=3*K1-2*E1;
F1:=EMA(J1,12);
F2:=REF(F1,1);
AA1:=(3*C+HIGH+LOW+O)/6;
CXH1:=(8*AA1+7*REF(AA1,1)+6*REF(AA1,2)+5*REF(AA1,3)+4*REF(AA1,4)+3*REF(AA1,5)+2*REF(AA1,6)+REF(AA1,8))/36;
CXH2:=(HHV(CXH1,5)+HHV(CXH1,10)+HHV(CXH1,20))/3;
CXH3:=(LLV(CXH1,5)+LLV(CXH1,10)+LLV(CXH1,20))/3;
CXH4:=(HHV(CXH2,5)+HHV(CXH2,10)+HHV(CXH2,20))/3;
CXH5:=(LLV(CXH3,5)+LLV(CXH3,10)+LLV(CXH3,20))/3;
CXH6:=(LLV(CXH1,2)+LLV(CXH1,4)+LLV(CXH1,6))/3;
DRAWBAND(CXH1,RGB(80,50,50),CXH6,RGB(250,250,0));
C1:CXH1,COLORYELLOW,LINETHICK1;
C2:CXH6,COLORGREEN,LINETHICK2;
C3:IF(CXH1>CXH6 AND CXH6>=REF(CXH6,1),CXH6,DRAWNULL),COLORRED,LINETHICK2;
P2:EMA(C,50),COLORGREEN,LINETHICK3;
IF(P2>REF(P2,1), P2,DRAWNULL),COLORRED,LINETHICK3;
HH:=HHV(H,3);
LL:=LLV(L,3);
HH1:=BARSLAST((HH > REF(HH,1)));
LL1:=BARSLAST((LL < REF(LL,1)));
STICKLINE((HH1 < LL1),C,O,2,0),COLORRED;
STICKLINE((HH1 < LL1),H,L,0,0),COLORRED;
STICKLINE((HH1 > LL1),C,O,2,0),COLORGREEN;
STICKLINE((HH1 > LL1),H,L,0,0),COLORGREEN;
多:= CROSS(CXH1>CXH6,0.5) AND CROSS(LL1,HH1);
多1:=BARSLAST(REF(多,1));
多2:=C>REF(CLOSE,多1+1) AND 多;
多3:=FILTER(多2,20) AND P2>REF(P2,1);
DRAWTEXT(多3 ,LL,'↑多 ');
空:=CROSS(CROSS(HH1,LL1),0.5) ;
空1:=BARSLAST(REF(空,1));
空2:=C<REF(CLOSE,空1+1) AND 空;
空3:=FILTER(空2,20)AND CROSS(CXH1=CXH6,0.5);
DRAWTEXT(空3 ,HH,'↓空'),COLORYELLOW;
BDGD:=C=HHV(CLOSE,M);
GDSJ:=BARSLAST(FILTER(CROSS(0.08,BDGD),M1))+1;
GD:REF(HIGH,GDSJ),COLOR00FF00,POINTDOT,LINETHICK1;
TPP:=CROSS(CLOSE,REF(GD,1)),COLOR0000FF,POINTDOT,LINETHICK0;
STICKLINE(GDSJ<=6,GD,GD,8,0),COLOR0000FF;
DRAWICON(GDSJ=1,H,39);
BDDD:=C=LLV(CLOSE,N);
DDSJ:=BARSLAST(FILTER(CROSS(0.08,BDDD),N1))+1;
DD1:REF(LOW,DDSJ),COLORYELLOW,POINTDOT,LINETHICK1;
STICKLINE(DDSJ<=6,DD1,DD1,8,0),COLORYELLOW;
DRAWICON(DDSJ=1,L,1);
LC:=REF(C,1);
WRSI:=SMA(MAX(C-LC,0),14,1)/SMA(ABS(C-LC),14,1)*100;
XG10:=CROSS(20,WRSI);
XGT4:=BARSLAST(XG10);
AD4:=REF(LOW,REF(XGT4,1)+1);
XG11:=REF(XGT4,1)>20 AND XG10 ;
DRAWICON(XG11,L,38);
ZS:=REF(C,1);
QS:=SMA(MAX(C-ZS,0),8,1)/SMA(ABS(C-ZS),8,1)*100,COLOR0080FF,LINETHICK2;
XX:=20;
SS:=80;
ZZ:=50;
XG1:=CROSS(80,QS) ;
XG2:=CROSS(QS,15);
XG3:=CROSS(QS,19);
D1:=FILTER(XG1,10);
D2:=FILTER(XG2,10);
D3:=FILTER(XG3,10);
STICKLINE(D1 AND C<O,C,O,3.6,0 ),COLOR00FFFF;
STICKLINE(D3 AND C>O,C,O,3.6,0 ),COLORFF00FF;
DRAWICON(D2,L*0.999,25);
XGT2:=BARSLAST(XG1);
AD2:=REF(LOW,REF(XGT2,1)+1);
XG6:= REF(XGT2,1)>10 AND XG1 ;
XGT3:=BARSLAST(XG2);
AD3:=REF(LOW,REF(XGT3,1)+1);
XG8:= REF(XGT3,1)>20 AND XG2;
BB32: IF(BARSLAST(XG6)<=30AND (REF(HIGH,BARSLAST(XG6)))=REF(REF(HIGH,BARSLAST(XG6)),1),REF(HIGH,BARSLAST(XG6)),DRAWNULL)DOTLINE,COLORMAGENTA;
DRAWICON(XG6,H*1.001,2);
DRAWICON(XG8,L,1);
A5:=3*SMA((C-LLV(L,18))/(HHV(H,18)-LLV(L,18))*100,21,1)-2*SMA(SMA((C-LLV(L,18))/(HHV(H,18)-LLV(L,18))*100,20,1),8,1);
AQW:=20;
ZQ:=CROSS(A5,AQW);
ZQ2:=FILTER(ZQ,20);
DRAWTEXT(ZQ2,L*0.999,'↑转'),COLOR0000FF;
CXH21:=(C-LLV(L,36))/(HHV(H,36)-LLV(L,36))*100;
CXH22:=SMA(CXH21,3,1);
CXH23:=SMA(CXH22,3,1);
CXH24:=SMA(CXH23,3,1);
波:= CXH23;
段:= CXH24;
CXH26:=CROSS(CXH23,CXH24) AND CXH23<20;
CD:=FILTER(CROSS(CXH23,CXH24),10) ;
A26:=HH1>LL1;
CXH27:=CROSS(CXH24,CXH23) AND CXH23>80;
小顶:=FILTER(CXH27,5) AND C<CXH6 AND A26 AND NOT(CXH1>CXH6);
DRAWTEXT(小顶 ,HH,'↓空'),COLORGREEN;
CXH13:=REF(C,1);
CXH14:=((SMA(MAX((C - CXH13),0),17,1) / SMA(ABS((C - CXH13)),17,1)) * 100);
空4:=CROSS(80,CXH14);
高:=FILTER(空4,10);
DRAWTEXT(高 ,HH,'↓高'),COLORMAGENTA;
公式导入教程: 【通达信公式源码导入方法教程】 【同花顺公式源码导入方法教程】 【大智慧新一代公式源码导入方法教程】
有思路,想编写各种指标公式,交易模型,选股公式,还原公式的朋友
可联系技术人员 QQ: 262069696 或微信:cxhjy888 进行 有偿收费 编写!(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,加好友时请简单备注下您的需求,否则无法通过。谢谢您!)
(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,加好友时请简单备注下您的需求,否则无法通过。谢谢您!)
相关文章
-
没有相关内容