文华黄经双线买卖指标源码
-
相关简介:文华指标源码: NN:=BARSLAST(DATEREFX(DATE,1)); CC:=VALUEWHEN(DATEREF(DATE,1),REF(OPI,1)); QQ:=OPI-REF(OPI,1); K1:=IFELSE(CLOSEOPENQQ=0,QQ,0); KK1:=IFELSE(CLOSEOPENQQ0,QQ,0); KKK1:=IFELSE(CLOSE=OPEN,QQ*0.5,0); K2:=IFELSE(CLOSEOPENQQ=0,QQ,0); KK2:=IFELSE(CLOS
-
文章来源:股海网作者:股海网发布时间:2013-09-04浏览次数:
文华指标源码:
NN:=BARSLAST(DATE<>REFX(DATE,1));
CC:=VALUEWHEN(DATE<>REF(DATE,1),REF(OPI,1));
QQ:=OPI-REF(OPI,1);
K1:=IFELSE(CLOSE>OPEN&&QQ>=0,QQ,0);
KK1:=IFELSE(CLOSE<OPEN&&QQ<0,QQ,0);
KKK1:=IFELSE(CLOSE=OPEN,QQ*0.5,0);
K2:=IFELSE(CLOSE<OPEN&&QQ>=0,QQ,0);
KK2:=IFELSE(CLOSE>OPEN&&QQ<0,QQ,0);
KKK2:=IFELSE(CLOSE=OPEN,QQ*0.5,0);
DO:=SUM(K1,NN)+SUM(KK1,NN)+SUM(KKK1,NN);
KO:=SUM(K2,NN)+SUM(KK2,NN)+SUM(KKK2,NN);
PARTLINE(LOW>0,DO,COLORYELLOW);
PARTLINE(LOW>0,KO,COLORGREEN);
W:=MOD(NN,4);
J:=BACKSET(ISLASTBAR,4);
DRAWNUMBER(ISLASTBAR,DO,DO,0,COLORYELLOW);
DRAWNUMBER(ISLASTBAR,KO,KO,0,COLORGREEN);
DRAWNUMBER(W=0&&J=0,DO,DO,0,COLORYELLOW);
DRAWNUMBER(W=0&&J=0,KO,KO,0,COLORGREEN);
VERTLINE(BARSLAST(DATE=REFX(DATE,1))=2,COLORMAGENTA);