{结果从0到13,依次分别是1/5/15/30/60分钟,日/周/月,多分钟,多日/季/年,5秒线/多秒线,13以上为自定义周期} ZQ:IF(PERIOD=0,250, IF(PERIOD=1,49, IF(PERIOD=2,1, IF(PERIOD=3,40, IF(PERIOD=4,60,60))))),NODRAW; GAPUP:=L>REF(H,1),STICK; TS:=CURRBARSCOUNT; TS1:=BARSSINCE(C); 常数:=CONST(BARSSINCE(C)); C1:=REFX(C,常数-TS1*2+2); C2:=REF(C,常数-TS*2+2); O1:=REFX(O,常数-TS1*2+2); O2:=REF(O,常数-TS*2+2); H1:=REFX(H,常数-TS1*2+2); H2:=REF(H,常数-TS*2+2); L1:=REFX(L,常数-TS1*2+2); L2:=REF(L,常数-TS*2+2); CC:=IF(TS>TS1,C1,C2); OO:=IF(TS>TS1,O1,O2); LL:=IF(TS>TS1,L1,L2); HH:=IF(TS>TS1,H1,H2); 回补上缺口:=HH<REF(LL,1); 信号1:=回补上缺口 AND REF(LLV(LL,TS1),1)>HH; 返信号1:=CROSS(SUM(信号1,TS1)=1,0.5); 低价:=IF(返信号1,REF(LLV(LL,TS1),1),0); 低价横线:=REF(低价,BARSLAST(返信号1)); 正信号:=REF(HH,BARSLAST(返信号1))=H AND REF(LL,BARSLAST(返信号1))=L AND REF(CC,BARSLAST(返信号1))=C AND REF(OO,BARSLAST(返信号1))=O; A2:=BARSLAST(正信号),NODRAW; A3:IF(A2=DRAWNULL,0,A2),NODRAW; A1:BETWEEN(A3,1,ZQ); JC:C-REF(H,A2),NODRAW; JC百分比:100*JC/C,NODRAW; LLL:L=LLV(L,A3),COLORWHITE,NODRAW; DRAWICON(LLL AND A3>2,0.5,1);
标签:30min,TS,通达信,1min,NODRAW,常数,REF,BARSLAST,TS1 From: https://www.cnblogs.com/ip99/p/17511689.html