VAR1:=1000;
VAR2:=10;
VAR3:=3;
VAR4:=TOTALBARSCOUNT<VAR1;
VAR5:=IF(VAR4,TOTALBARSCOUNT,VAR1);
VAR6:=CURRBARSCOUNT>VAR5;
VAR7:=IF(VAR6,0,VAR5);
VAR8:=IF(C>REF(C,1),vol,-VOL);
VAR9:=SUM(VAR8,0)/CAPITAL;
VAR10:=IF(VAR7,VAR9,DRAWNULL);
VAR11:=MA(VAR10,VAR3)>=REF(MA(VAR10,VAR3),1);
VAR17:=crOSS(MA(VAR10,VAR3),MA(VAR10,VAR2));
VAR18:=VAR17 AND NOT(C<REF(C,1)) AND NOT(REF((VAR7 AND VAR11),1));
XG:VAR18;