//////////////
CN1:=HHV(V,5);CN2:=O>C;
CN02:=C>O;
CN03:=C=O;
CN04:=((SUM(V,5)/CN1));
CN05:=IF(CN04>0.3,1,0);
CN06:=IF(CN2 AND CN05,V,0);
CN07:=IF(CN02 AND CN05,V,0);
CN08:=IF(CN03 AND CN05,V,0);
AD:SUM(CN07,3),coloryellow,LINETHICK2;
DA:=SUM(CN06,3);
AZ:(AD-DA),COLOR0000FF,LINETHICK2;
AF:=AZ=AD;
AX:=AD*0.6;
SA:=BETWEEN(AZ,AD,AX);
0,colorgray;
///////黄柱·绿柱///////
VAR1:=(HHV(HIGH,9)-CLOSE)/(HHV(HIGH,9)-LLV(LOW,9))*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;
S: IF(VAR6>100,VAR6-100,0),LINETHICK1,nodraw;
STICKLINE(REF(S,1)<S,S,REF(S,1),3,0),coloryellow,LINETHICK15;
STICKLINE(REF(S,1)>S,S,REF(S,1),3,0),colorblue,LINETHICK15;
/////////实验////////
CN1:=HHV(V,5);CN2:=O>C;
CN02:=C>O;
CN03:=C=O;
CN04:=((SUM(V,5)/CN1));
CN05:=IF(CN04>0.3,1,0);
CN06:=IF(CN2 AND CN05,V,0);
CN07:=IF(CN02 AND CN05,V,0);
CN08:=IF(CN03 AND CN05,V,0);
AD:SUM(CN07,3),coloryellow,LINETHICK2;
DA:=SUM(CN06,3);
AZ:(AD-DA),COLOR0000FF,LINETHICK2;
AF:=AZ=AD;
AX:=AD*0.6;
SA:=BETWEEN(AZ,AD,AX);
0,colorgray;
/////////实验////////
///////底顶部BS背离///////
LC:=REF(CLOSE,1);
RSI:=((SMA(MAX((CLOSE - LC),0),3,1) / SMA(ABS((CLOSE - LC)),3,1)) * 100);
FF:=EMA(CLOSE,3);
MA15:=EMA(CLOSE,21);
DRAWTEXT(CROSS(FF,MA15),(LOW * 0.99),'.底背离'),colorred;
{DRAWICON(CROSS(FF,MA15),(LOW * 0.99),7); }
RSI1:=((SMA(MAX((CLOSE - (REF(CLOSE,1))),0),3,1) / SMA(ABS((CLOSE - (REF(CLOSE,1)))),3,1))* 100);
DRAWTEXT(CROSS(88,RSI1) AND (MA(C,3))>(EMA(C,3)) ,(HIGH + 0.3),'.顶背离'),colorgreen;
{DRAWICON(CROSS(88,RSI1) AND (MA(C,3))>(EMA(C,3)) ,(HIGH + 0.3),8); }
AA:=(HHV(HIGH,20) - (2 * ATR));
BB:=CROSS(CLOSE,REF(HHV(HIGH,55),1));
SSS:=CROSS(MIN(MA(CLOSE,13),AA),CLOSE);
BBB:=BARSLAST(BB);
SSSB:=BARSLAST(SSS);
B1:=((BBB = 0) AND (REF(SSSB,1) < REF(BBB,1)));
B1B:=BARSLAST(B1);
B2:=((((BB = 1) AND (B1B < SSSB)) AND (B1B > 0)) AND (COUNT(BB,SSSB) < 3));
B2B:=BARSLAST(B2);
B3:=((((BB = 1) AND (B2B < B1B)) AND (COUNT(BB,SSSB) < 4)) AND (COUNT(BB,SSSB) > 2));
DRAWTEXT((B1 = 1),(LOW - 0.6),'.跟进'),coloryellow;
DRAWTEXT((B2 = 1),(LOW - 0.6),'.加码'),COLORFFAAFF;
//////////////
//////////////
//////////////