通达信指标公式源码粉红色线主图指标
V2:=IF(CURRBARSCOUNT=1,VOL*240/FROMOPEN/REF(VOL,1)-1,VOL/REF(VOL,1)-1);
HSL:=100*VOL/(CONST(FINANCE(7))/100);
HS:=IF(BETWEEN(HSL,0,1000000),HSL,VOL);
STICKLINE(V2>=0.9 AND C>O,C,O,3,0),COLORAA00AA;
STICKLINE(V2>=0.9 AND C>O,C,O,2,0),COLORAA00CC;
STICKLINE(V2>=0.9 AND C>O,C,O,1,0),COLORAA00DD;
STICKLINE(V2>=0.9 AND C>O,H,L,0,0),COLOR0000FF;
N:=5;
XB1:=TROUGH(2,N,1),COLORGRAY;
CB1:=CONST(TROUGHBARS(2,N,1));
B1:=IF(CURRBARSCOUNT
STICKLINE(1,B1,B1,3,1),COLORGRAY;
XB2:=TROUGH(2,N,2),COLORGRAY;
CB2:=CONST(TROUGHBARS(2,N,2));
B2:=IF(CURRBARSCOUNT
STICKLINE(1,B2,B2,3,1),COLORGRAY;
XB3:=TROUGH(2,N,3),COLORGRAY;
CB3:=CONST(TROUGHBARS(2,N,3));
B3:=IF(CURRBARSCOUNT
STICKLINE(1,B3,B3,3,1),COLORGRAY;
XB4:=TROUGH(2,N,4),COLORGRAY;
CB4:=CONST(TROUGHBARS(2,N,4));
B4:=IF(CURRBARSCOUNT
STICKLINE(1,B4,B4,3,1),COLORGRAY;
XB5:=TROUGH(2,N,5),COLORGRAY;
CB5:=CONST(TROUGHBARS(2,N,5));
B5:=IF(CURRBARSCOUNT
STICKLINE(1,B5,B5,3,1),COLORGRAY;
XB6:=TROUGH(2,N,6),COLORGRAY;
CB6:=CONST(TROUGHBARS(2,N,6));
B6:=IF(CURRBARSCOUNT
STICKLINE(1,B6,B6,3,1),COLORGRAY;
XT1:=PEAK(1,N,1),COLORGRAY;
CT1:=CONST(PEAKBARS(1,N,1));
T1:=IF(CURRBARSCOUNT
STICKLINE(1,T1,T1,3,1),COLORLIRED;
XT2:=PEAK(1,N,2),COLORGRAY;
CT2:=CONST(PEAKBARS(1,N,2));
T2:=IF(CURRBARSCOUNT
STICKLINE(1,T2,T2,3,1),COLORLIRED;
XT3:=PEAK(1,N,3),COLORGRAY;
CT3:=CONST(PEAKBARS(1,N,3));
T3:=IF(CURRBARSCOUNT
STICKLINE(1,T3,T3,3,1),COLORLIRED;
XT4:=PEAK(1,N,4),COLORGRAY;
CT4:=CONST(PEAKBARS(1,N,4));
T4:=IF(CURRBARSCOUNT
STICKLINE(1,T4,T4,3,1),COLORLIRED;
XT5:=PEAK(1,N,5),COLORGRAY;
CT5:=CONST(PEAKBARS(1,N,5));
T5:=IF(CURRBARSCOUNT
STICKLINE(1,T5,T1,3,1),COLORLIRED;
XT6:=PEAK(1,N,6),COLORGRAY;
CT6:=CONST(PEAKBARS(1,N,6));
T6:=IF(CURRBARSCOUNT
STICKLINE(1,T6,T6,3,1),COLORLIRED;
风险提示:本指标公式仅作为知识分享,不构成任何投资建议,不作投资依据。