请帮转换成文化指标,谢谢! [文华财经]
-
咨询内容:
WO1:="周K线的引用.O1#WEEK";
WC:="周K线的引用.C1#WEEK";
WH:="周K线的引用.H1#WEEK";
WL:="周K线的引用.L1#WEEK";
K1:=WO1=REF(WO1,1) AND WC=REF(WC,1) AND WH=REF(WH,1) AND WL=REF(WL,1);
K3:=REF(C,1)=DYNAINFO(3) AND O=DYNAINFO(4) AND C=DYNAINFO(7) AND H=DYNAINFO(5) AND L=DYNAINFO(6);
DD:=REF(BARSLAST(K1=0)+1,1),LINETHICK0;
DD1:=CROSS(BACKSET((K1=0 OR K3) AND DD=5,4),0.5),NODRAW;
DD2:=CROSS(BACKSET((K1=0 OR K3) AND (DD=4 OR DD=3),3),0.5),NODRAW;
DD3:=CROSS(BACKSET((K1=0 OR K3) AND DD<=2,2),0.5),LINETHICK0;
BK1:=DD1 OR DD2 OR DD3;
BK2:=CROSS(BACKSET(K1=0,2),0.5);
BK3:=CROSS(BACKSET(K1=0 AND REF(K1=0,1),2),0.5);
WO:IF(BARSLAST(K1=0)=0,O,REF(O,BARSLAST(K1=0))),NODRAW;
五周:MA(C,25);
十周:MA(C,50);
二十周:MA(C,100),COLORRED;
K0:=WC>WO OR (WC=WO AND WC>REF(WC,BARSLAST(K1=0)+1));
STICKLINE(K0 AND BK1,WH,WC,0,0),COLORLIMAGENTA;
STICKLINE(K0 AND BK1,WO,WL,0,0),COLORLIMAGENTA;
STICKLINE(K0 AND K1=0,WC,WO,0,0),COLORLIMAGENTA;
STICKLINE(K0 AND (BK2 OR K3),WC,WO,0,0),COLORLIMAGENTA;
STICKLINE(K0 AND ((K1 AND BK2=0 AND K3=0) OR BK3),WC,WC,8,1),COLORLIMAGENTA;
STICKLINE(K0 AND ((K1 AND BK2=0 AND K3=0) OR BK3),WO,WO,8,1),COLORLIMAGENTA;
STICKLINE(NOT(K0) AND BK1,WH,WO,0,0),COLORCYAN;
STICKLINE(NOT(K0) AND BK1,WC,WL,0,0),COLORCYAN;
STICKLINE(NOT(K0) AND K1=0,WC,WO,0,0),COLORCYAN;
STICKLINE(NOT(K0) AND (BK2 OR K3),WC,WO,0,0),COLORCYAN;
STICKLINE(NOT(K0) AND ((K1 AND BK2=0 AND K3=0) OR BK3),WC,WC,8,1),COLORCYAN;
STICKLINE(NOT(K0) AND ((K1 AND BK2=0 AND K3=0) OR BK3),WO,WO,8,1),COLORCYAN;来源:程序化99
-
文华技术人员:
您1楼源码含有跨周期引用,其中O1 C1等是引用周K线的开盘价和收盘价?
来源: WWW.CXH99.COM
-
文华客服:
是的
-
网友回复:
参考:
WO1:="WEEK$1$OPEN";
WC:="WEEK$1$CLOSE";
WH:="WEEK$1$HIGH";
WL:="WEEK$1$LOW";
K1:=WO1=REF(WO1,1) AND WC=REF(WC,1) AND WH=REF(WH,1) AND WL=REF(WL,1);
K3:=REF(C,1)=REF(C,DAYBARPOS) AND O=VALUEWHEN(DAYBARPOS=1,O) AND H=HHV(H,DAYBARPOS ) AND L=LLV(L,DAYBARPOS);
DD:=REF(BARSLAST(K1=0)+1,1),LINETHICK1;
DD1:=CROSS(BACKSET((K1=0 OR K3) AND DD=5,4),0.5),NODRAW;
DD2:=CROSS(BACKSET((K1=0 OR K3) AND (DD=4 OR DD=3),3),0.5),NODRAW;
DD3:=CROSS(BACKSET((K1=0 OR K3) AND DD<=2,2),0.5),LINETHICK1;
BK1:=DD1 OR DD2 OR DD3;
BK2:=CROSS(BACKSET(K1=0,2),0.5);
BK3:=CROSS(BACKSET(K1=0 AND REF(K1=0,1),2),0.5);
WO:IF(BARSLAST(K1=0)=0,O,REF(O,BARSLAST(K1=0))),NODRAW;
五周:MA(C,25);
十周:MA(C,50);
二十周:MA(C,100),COLORRED;
K0:=WC>WO OR (WC=WO AND WC>REF(WC,BARSLAST(K1=0)+1));
STICKLINE(K0 AND BK1,WH,WC,0,0),COLORMAGENTA;
STICKLINE(K0 AND BK1,WO,WL,0,0),COLORMAGENTA;
STICKLINE(K0 AND K1=0,WC,WO,0,0),COLORMAGENTA;
STICKLINE(K0 AND (BK2 OR K3),WC,WO,0,0),COLORMAGENTA;
STICKLINE(K0 AND ((K1 AND BK2=0 AND K3=0) OR BK3),WC,WC,8,1),COLORMAGENTA;
STICKLINE(K0 AND ((K1 AND BK2=0 AND K3=0) OR BK3),WO,WO,8,1),COLORMAGENTA;
STICKLINE(NOT(K0) AND BK1,WH,WO,0,0),COLORCYAN;
STICKLINE(NOT(K0) AND BK1,WC,WL,0,0),COLORCYAN;
STICKLINE(NOT(K0) AND K1=0,WC,WO,0,0),COLORCYAN;
STICKLINE(NOT(K0) AND (BK2 OR K3),WC,WO,0,0),COLORCYAN;
STICKLINE(NOT(K0) AND ((K1 AND BK2=0 AND K3=0) OR BK3),WC,WC,8,1),COLORCYAN;
STICKLINE(NOT(K0) AND ((K1 AND BK2=0 AND K3=0) OR BK3),WO,WO,8,1),COLORCYAN;
有思路,想编写各种指标公式,程序化交易模型,选股公式,预警公式的朋友
可联系技术人员 QQ: 1145508240 或微信号:cxh99cxh99 进行 有偿收费 编写!(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,谢谢您!)
相关文章
-
没有相关内容