转折点指标-精品通达信指标公式源码分享

通达信免费指标 10-22 阅读:83 评论:0

image.png

{通达信用的:}       

{INPUT: N(3,1,100);}       

N:=3;       

{转折点}       

Z_1:=(EMA(C,N)-REF(EMA(C,N),1))/REF(EMA(C,N),1)*100;       

Z_2:=IF(Z_1<0,REF(Z_1,BARSLAST(CROSS(0,Z_1))+1),0);       

Z_3:=IF(Z_1>0,REF(Z_1,BARSLAST(CROSS(0,Z_1))+1),0);       

Z_4:=IF(CROSS(0,Z_1),H,L);           

DRAWLINE(CROSS(Z_2,Z_3),H,CROSS(Z_3,Z_2),L,0),LINETHICK2,COLORWHITE;       

DRAWLINE(CROSS(Z_3,Z_2),L,CROSS(Z_2,Z_3),H,0),LINETHICK2,COLORMAGENTA;       

DRAWLINE(CROSS(0,Z_1)||CROSS(Z_1,0),Z_4,ISLASTBAR,Z_4,0),LINETHICK2,COLORGREEN;


{飞狐用的:}       

INPUT: N(3,1,100);           

{转折点}       

Z_1:=(EMA(C,N)-REF(EMA(C,N),1))/REF(EMA(C,N),1)*100;       

Z_2:=IF(Z_1<0,REF(Z_1,BARSLAST(CROSS(0,Z_1))+1),0);       

Z_3:=IF(Z_1>0,REF(Z_1,BARSLAST(CROSS(0,Z_1))+1),0);       

Z_4:=IF(CROSS(0,Z_1),H,L);            

DRAWLINE(CROSS(Z_2,Z_3),H,CROSS(Z_3,Z_2),L,0),LINETHICK2,COLORWHITE;       

DRAWLINE(CROSS(Z_3,Z_2),L,CROSS(Z_2,Z_3),H,0),LINETHICK2,COLORMAGENTA;       

DRAWLINE(CROSS(0,Z_1)||CROSS(Z_1,0),Z_4,ISLASTBAR,Z_4,0),LINETHICK2,COLORGREEN; 


版权声明

本文版权归掌上指标所有。
未经许可,不得转载,转载请注明出处!

服务热线

18020657357

微信客服

微信客服