VAR1A:=((HHV(H,21)-C)/(HHV(H,21)-LLV(L,21)))*100-10;
VAR2A:=((C-LLV(L,21))/(HHV(H,21)-LLV(L,21)))*100;
VAR3A:=SMA(VAR2A,13,8);
VAR4A:=SMA(VAR1A,21,8);
XA:=CEILING(SMA(VAR3A,13,8));
X1A:=XA-VAR4A ;
A:=XA-VAR4A<(-80);
VAR1B:=REF(CLOSE,1);
VAR2B:=REF(VOL,1);
VAR3B:=((CLOSE - VAR1B) / (CLOSE + VAR1B));
VAR4B:=((VOL - VAR2B) / (VOL + VAR2B));
VAR5B:=(SUM(ABS(VAR4B),12) / SUM(ABS(VAR3B),12));
VAR6B:=((SMA(MAX((CLOSE - VAR1B),0),12,1) / SMA(ABS((CLOSE - VAR1B)),12,1)) * 100);
A1B:=((VAR5B < 6) AND (VAR6B < 25));
A2B:=((VAR5B < 7) AND (VAR6B < 30));
A3B:=((VAR5B < 8) AND (VAR6B < 31));
B:=(A1B OR A2B OR A3B) AND BARSCOUNT(CLOSE) > 60;
VAR1C:=(CLOSE-MA(CLOSE,48))/MA(CLOSE,48)*100<-25;
VAR2C:=(CLOSE-MA(CLOSE,70))/MA(CLOSE,70)*100<-27;
VAR3C:=VAR1C AND VAR2C;
PI:=VAR3C AND (CLOSE>OPEN*1.06 OR CLOSE>REF(CLOSE,1)*1.038) AND VOL<REF(VOL,1)*2.8 OR CLOSE<MA(CLOSE,48)*0.7 AND (COUNT(CLOSE<OPEN*0.97,2)=2 AND DPO>-3.7 OR COUNT(HIGH/LOW>1.065,5)>3);
PIP:=(CLOSE/REF(CLOSE,20)-1)*100<-13 AND (C/REF(C,20)-1)*100<-20;
PIPI:=CLOSE/(EMA(EMA((C+L+H)/3,3),26)*0.9)<0.95 ;
PIPIP:=(CLOSE-MA(CLOSE,58))/MA(CLOSE,58)<-0.2245;
A AND B AND PI AND PIP AND PIPI AND PIPIP, COLORRED;