以下是通达信闪电起爆源码
闪电起爆源码
VAR1:=100*(CLOSE-REF(CLOSE,1))/REF(CLOSE,1);
VAR2:=IF(CLOSE<REF(OPEN,1) AND VAR1<0,1,0);
VAR3:=VAR2;
VAR4:=IF(CLOSE<REF(OPEN,2) AND VAR1<0,1,0);
VAR5:=VAR4;
VAR6:=CLOSE/REF(CLOSE,1)>1.035;
VAR7:=HIGH>=HHV(HIGH,5);
VAR8:=BARSLAST(VAR7);
VAR9:=IF(LOW<0.989*REF(LOW,VAR8),1,0);
VAR10:=VAR9 AND COUNT(VAR9,VAR8)<2 AND VAR8<30 AND VAR8>0;
VAR11:=REF(CLOSE<OPEN,1) AND CLOSE>OPEN;
VAR12:=BARSLAST(VAR10);
VAR13:=IF(LOW<0.989*REF(LOW,VAR12),1,0);
VAR14:=VAR13 AND COUNT(VAR13,VAR12)<2 AND VAR12<30 AND VAR8>0 AND VAR12>0;
VAR15:=BARSLAST(VAR14);
VAR16:=IF(LOW<0.989*REF(LOW,VAR15),1,0);
VAR17:=REF(CLOSE>OPEN OR OPEN>CLOSE,8);
VAR18:=VAR16 AND COUNT(VAR16,VAR15)<2 AND VAR15<30 AND VAR8>0 AND VAR12>0 AND VAR15>0;
VAR19:=VAR3=0 AND REF(VAR3,1)=1 AND VAR5=0 AND REF(VAR5,1)=1;
VAR20:=EMA(CLOSE,12)-EMA(CLOSE,26);
VAR21:=EMA(VAR20,9);
VAR22:=2*(VAR20-VAR21);
VAR23:=REF(VAR22,1)<REF(VAR22,2) AND VAR22>=0 AND VAR22>REF(VAR22,1) AND VAR17;
VAR24:=MA(CLOSE,5);
VAR25:=MA(CLOSE,10);
VAR26:=MA(CLOSE,20);
VAR27:=CROSS(CLOSE,VAR24) AND CROSS(CLOSE,VAR25) AND CROSS(CLOSE,VAR26) AND VAR6;
VAR28:=VAR19 AND (REF(VAR14,1) OR REF(VAR18,1) OR REF(VAR18,2)) AND VAR23 AND VAR27 AND VAR11;
STICKLINE(VAR28,2,100,0.3,0),COLOR000099;
STICKLINE(VAR28,2,100,0.2,0),COLOR0000CC;
STICKLINE(VAR28,2,100,0.1,0),COLORRED;
STICKLINE(VAR28,2,100,0,0),COLORCC66FF;
DRAWTEXT(VAR28,95,71),COLORYELLOW;
DRAWTEXT(VAR28,75,72),COLORYELLOW;
DRAWTEXT(VAR28,55,73),COLORYELLOW;
DRAWTEXT(VAR28,35,74),COLORYELLOW;
评论(0)