以下是同花顺顶底KD副图指标

同花顺顶底KD副图指标

源码

n:=81;
 m:=3;

var1:=(HHV(HIGH,5)-LLV(LOW,5));
var2:=(HHV(HIGH,5)-CLOSE);
var3:=(CLOSE-LLV(LOW,5));
var4:=var2/var1*100-70 ;
var5:=(CLOSE-LLV(LOW,30))/(HHV(HIGH,30)-LLV(LOW,30))*100;
var6:=(2*C+H+L)/4;
var7:=SMA((var3/var1*100),3,1); 
var8:=LLV(LOW,10);
var9:=SMA(var7,3,1)-SMA(var4,9,1);
var10:= IF(var9>100,var9-100,0);
varA:=HHV(HIGH,10);
B:=EMA((var6-var8)/(varA-var8)*100,8),COLORffcc66;
B1:=EMA(B,5);
STICKLINE(B>0 AND B-B1>=0,79,80,8,0),colorred,linethick2;
STICKLINE(B>0 AND B-B1<0,79,80,8,0),COLOR00FF00,linethick2;
s:50;
STICKLINE(B>0 AND B-B1>=0,19,20,8,0),colorred,linethick2;
STICKLINE(B>0 AND B-B1<0,19,20,8,0),COLOR00FF00,linethick2;

STICKLINE(B-B1>0,B,B1,8,1),colorred;
STICKLINE(B-B1<0,B,B1,8,1),COLOR00ff00;
LOWV:=LLV(LOW,N);
HIGHV:=HHV(HIGH,N);
RSV:=EMA((CLOSE-LOWV)/(HIGHV-LOWV)*100,M);
K:EMA(RSV,M);
D:MA(K,M);
XX:IF(K<=D,K,D);
D1:MA(K,M);
大头部:IF((D>(85)),20,0);
卖出:IF(K>80,80,95);
买入:IF(CROSS(K,20),6,0);
头部:IF((K>(80)),6,0);

声明:本站所有文章,如无特殊说明或标注,均为本站原创发布。任何个人或组织,在未征得本站同意时,禁止复制、盗用、采集、发布本站内容到任何网站、书籍等各类媒体平台。如若本站内容侵犯了原著者的合法权益,可联系我们进行处理。