【通达信源码分享】精品指标公式-KST价格指标源码
2023-01-10未知 编 辑:掌上指标
公式源码:
A:=CLOSE;
A1:0,DOTLINE,POINTDOT,LINETHICK3,COLORFF00FF;
{A:=VOL;}
ROC1:=100*(A-REF(A,N1))/REF(A,N1);
ROC2:=100*(A-REF(A,N2))/REF(A,N2);
ROC3:=100*(A-REF(A,N3))/REF(A,N3);
ROC4:=100*(A-REF(A,N4))/REF(A,N4);
KST:(MA(ROC1,N1)+2*MA(ROC2,N2)+3*MA(ROC3,N3)+4*MA(ROC4,N4))/10,COLORYELLOW,DOTLINE;
KSTMA4:MA(KST,4),COLORCYAN,DOTLINE;
KSTMA10:MA(KST,10),COLORRED,DOTLINE;
IF(KST>REF(KST,1),KST,DRAWNULL),COLORYELLOW,LINETHICK2;
IF(KSTMA4>REF(KSTMA4,1),KSTMA4,DRAWNULL),COLORCYAN,LINETHICK2;
IF(KSTMA10>REF(KSTMA10,1),KSTMA10,DRAWNULL),COLORRED,LINETHICK2;