以下是同花顺双堆棍主图公式

同花顺双堆棍主图公式

红色越多越好,买。绿色越多,就该卖了。太极神图之综合指标

源码

VAR1:=(HHV(HIGH,3)-CLOSE)/(HHV(HIGH,9)-LLV(LOW,21))*100-70;

VAR2:=SMA(VAR1,9,1)+100;

VAR3:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;

VAR4:=SMA(VAR3,3,1);

VAR5:=SMA(VAR4,3,1)+100;

VAR6:=VAR5-VAR2;

机构: IF(VAR6>100,VAR6-100,0)*2.5,COLORFF00FF,LINETHICK1;

DRAWBAND(10,RGB(0,0,0),机构,RGB(10,116,126));

EMA5:=EMA(C,5);

EMA10:=EMA(C,10);

EMA20:=EMA(C,20);

EMA30:=EMA(C,30);

EMA55:=EMA(C,55);

EMA120:=EMA(C,120);

A1:=EMA5>=REF(EMA5,1);

A2:=EMA5<REF(EMA5,1);

DRAWICON(A1,105,1);

DRAWICON(A2,105,2);

EMA5金叉:A1,NODRAW;

DRAWTEXT(ISLASTBAR=1,IF(A1,95,95),’-5金叉’),colorcyan;

B1:=EMA10>=REF(EMA10,1);

B2:=EMA10<REF(EMA10,1);

DRAWICON(B1,90,1);

DRAWICON(B2,90,2);

EMA10金叉:B1,NODRAW;

DRAWTEXT(ISLASTBAR=1,IF(B1,85,85),’-10金叉’),colorcyan;

C1:=EMA20>=REF(EMA20,1);

C2:=EMA20<REF(EMA20,1);

DRAWICON(C1,80,1);

DRAWICON(C2,80,2);

EMA20金叉:C1,NODRAW;

DRAWTEXT(ISLASTBAR=1,IF(C1,75,75),’-20金叉’),colorcyan;

D1:=EMA30>=REF(EMA30,1);

D2:=EMA30<REF(EMA30,1);

DRAWICON(D1,70,1);

DRAWICON(D2,70,2);

EMA30金叉:D1,NODRAW;

DRAWTEXT(ISLASTBAR=1,IF(D1,65,65),’-30金叉’),colorcyan;

E1:=EMA55>=REF(EMA55,1);

E2:=EMA55<REF(EMA55,1);

DRAWICON(E1,60,11);

DRAWICON(E2,60,2);

EMA55金叉:E1,NODRAW;

DRAWTEXT(ISLASTBAR=1,IF(E1,55,55),’-55金叉’),colorcyan;

MAV:=(C*2+H+L)*4;

SK:=EMA(MAV,13) – EMA(MAV,34);

SD:=EMA(SK,5);

多空: (2*(SK-SD))*30.8,colormagenta,NODRAW;

空方: (-2*(SK-SD))*30.8,colorligreen,NODRAW;

多1:=多空>=REF(多空,1);

多2:=多空<REF(多空,1);

DRAWICON(多1,50,13);

DRAWICON(CROSS(多空,空方),50,23);

DRAWICON(多2,50,14);

多空金叉:=多1,NODRAW;

DRAWTEXT(ISLASTBAR=1,IF(多1,45,45),’-多空’),colorcyan;

AB1:=(HHV(H,9)-C)/(HHV(H,9)-LLV(LOW,9))*100- 70;

AB2:=SMA(AB1,9,1)+100;

AB3:=(C-LLV(L,9))/(HHV(H,9)- LLV(L,9))*100;

AB4:=SMA(AB3,3,1);

AB5:=SMA(AB4,9,1)+100;

波段:AB5-AB2, colorgreen,NODRAW;

波段1:=波段>=REF(波段,1);

波段2:=波段<REF(波段,1);

DRAWICON(波段1,40,15);

DRAWICON(波段2,40,2);

机构金叉:=波段1,NODRAW;

DRAWTEXT(ISLASTBAR=1,IF(波段1,35,35),’-波段’),colorcyan;

成交量:VOL,colorbrown,NODRAW;

F1:=成交量>=REF(成交量,5);

F2:=成交量<REF(成交量,5);

DRAWICON(F1,30,1);

DRAWICON(F2,30,2);

成交量金叉:=F1,NODRAW;

DRAWTEXT(ISLASTBAR=1,IF(F1,25,25),’-成交量’),colorcyan;

量比:=IF(ISLASTBAR,(VOL/FROMOPEN)/(SUM(REF(VOL,1),5)/(240*5)),VOL/MA(REF(VOL,1),5))*5,NODRAW;

H1:=量比>=REF(量比,1);

H2:=量比<REF(量比,1);

DRAWICON(H1,20,1);

DRAWICON(H2,20,2);

量比金叉:=H1,NODRAW;

DRAWTEXT(ISLASTBAR=1,IF(H1,15,15),’-量比’),colorcyan;

LC:=REF(CLOSE,1),NODRAW;

RSI6:=SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100,NODRAW;

MA6 :=MA(RSI6,6),NODRAW;

趋势:IF(MA6>REF(MA6,1) OR RSI6>MA6,MA6,MA6),NODRAW;

J1:=趋势>=REF(趋势,1);

J2:=趋势<REF(趋势,1);

DRAWICON(J1,10,23);

DRAWICON(J2,10,2);

趋势金叉:=J1,NODRAW;

DRAWTEXT(ISLASTBAR=1,IF(J1,5,5),’-趋势’),colorcyan;

L1:=(CLOSE-LLV(LOW,11))/(HHV(HIGH,11)-LLV(LOW,11))*100,NODRAW;

K:SMA(L1,3,1),coloryellow,LINETHICK2;

D:SMA(K,3,1),colorwhite,LINETHICK2;

DRAWICON(CROSS(K,D),0,19);

 

 

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