A3:=REF(CLOSE,1.000);
A4:=SMA(MAX((CLOSE-A3),0),8,1)/SMA(Abs((CLOSE-A3)),8.000,1)*100;
A5:=SMA(MAX((CLOSE-A3),0),55,1)/SMA(ABS((CLOSE-A3)),55.000,1)*100;
超短线2:(((A4<=20) AND (A5<=49))*1);
超卖1:IF(SMA(MAX(CLOSE-REF(CLOSE,2),0),7,1)/SMA(ABS(CLOSE- REF(CLOSE,2)),7,1)*100<12,0.5,0);
超卖2:IF(SMA(MAX(CLOSE-REF(CLOSE,1),0),7,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),7,1)*100 <12,0.5,0);
买特灵:超短线2 OR 超卖1 OR 超卖2;
MA5:=MA(CLOSE,5);
MA10:=MA(CLOSE,10);
MA60:=MA(CLOSE,60);
PDAY1:=BARSLAST(crOSS(MA60,MA5));{5日均线下穿60日均线}
PDAY2:=BARSLAST(CROSS(MA60,MA10));{10日均线下穿60日均线,至此形成鸭颈部}
PDAY3:=BARSLAST(LOW=LLV(LOW,PDAY2));{形成头部,要反弹}
PDAY4:=BARSLAST(CROSS(MA5,MA10));{反弹后,5日均线和10日均线金叉}
PDAY5:=BARSLAST(CROSS(MA10,MA5));{反弹不久,5日均线和10日均线形成死叉,形成嘴部}
A1:=PDAY1>PDAY2 AND PDAY2>PDAY3 AND PDAY3>PDAY4 AND PDAY4>PDAY5 AND PDAY5<5;
A2:=COUNT(CROSS(MA10,MA5),PDAY2)=1;
鸭头:A1 AND A2,COLOR000099;
M2:=EMA(C,5);
M18:=EMA(C,18);
买点:=IF(CROSS(M18,M2),5,10* 10000),COLORGREEN,LINETHICK1;
LC:=REF(CLOSE,1);
rsi5:=((SMA(MAX((CLOSE-LC),0),5,1)/SMA(ABS((CLOSE-LC)),5,1))*100);
TR1:=SUM(MAX(MAX((HIGH-LOW),ABS((HIGH-REF(CLOSE,1)))),ABS((LOW-REF(CLOSE,1)))),10);
HD:=(HIGH-REF(HIGH,1));
LD:=(REF(LOW,1)-LOW);
DMP:=SUM(IF(((HD>0) AND (HD>LD)),HD,0),10);
DMM:=SUM(IF(((LD>0) AND (LD>HD)),LD,0),10);
PDI:=((DMP*100)/TR1);
mdi:=((DMM*100)/TR1);
ADX:=MA(((ABS((MDI-PDI))/(MDI+PDI))*100),5);
AV:=(RSI5+ADX);
DXR:=(((ADX+REF(ADX,5))/2)+RSI5);
wr10:=((100*(HHV(HIGH,10)-CLOSE))/(HHV(HIGH,10)-LLV(LOW,10)));
NEWvol:=(RSI5-WR10);
选出后观察:=(AV+NEWVOL);
底部特征选股:=IF(CROSS(选出后观察,0),1,0);
VAR1:=SMA(底部特征选股,3,1);
VAR2:=SMA(VAR1,3,1);
VAR3:=SMA(VAR2,3,1);
底买入:IF(CROSS(VAR2,VAR3) AND (VAR2<40),0.8,0);
SM01:=MA((2*C+H+L)/4,5);
SM02:=SM01*(200-102)/100;
SM03:=(1-7/100)*DMA(C,ABS((2*C+H+L)/4-MA(C,20))/MA(C,20));
SM04:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;
SM05:=3*SMA(SM04,3,1)-2*SMA(SMA(SM04,3,1),3,1);
SM06:=((H+L+C)/3-MA((H+L+C)/3,14))/(0.015*AVEDEV((H+L+C)/3,14));
SM07:=SM02<SM03&&SM05>REF(SM05,1)&&REF(SM05,1)<REF(SM05,2)&&SM06<-100&&SM06>REF(SM06,1);
STICKLINE(SM07,0,0.5,2,0),COLORYELLOW;
主力入场:SM07,COLORRED,LINETHICK3;
VA:=IF(CLOSE>REF(CLOSE,1),VOL,-VOL);
obv1:=SUM(IF(CLOSE=REF(CLOSE,1),0,VA),0);
OBV2:=EMA(OBV1,3)-MA(OBV1,9);
OBV3:=EMA(IF(OBV2>0,OBV2,0),3);
MAC3:=MA(C,3);
SHORT:=12;LONG:=26;MID:=9;
DIF:=EMA(CLOSE,SHORT)-EMA(CLOSE,LONG),COLORYELLOW ;
DEA:=EMA(DIF,MID),COLORFF9900 ;
macd:=(DIF-DEA)*2;
入1:=IF(DIF>REF(DIF,1),DIF,DRAWNULL),COLORRED,LINETHICK2;
入2:=IF(DIF<REF(DIF,1),DIF,DRAWNULL),COLOR00FF00,LINETHICK2;
低位金叉:=CROSS(DIF,DEA) AND DIF<-0.1;
STICKLINE(低位金叉,0,0.08,2,0),COLORFF00FF;
DRAWTEXT(低位金叉,0.16,' 低位金叉'),COLORWHITE;
JCCOUNT:=COUNT(CROSS(DIF,DEA),BARSLAST(DEA>=0));
二次金叉:=CROSS(DIF,DEA) AND DEA<0 AND COUNT(JCCOUNT=2,21)=1;
STICKLINE(二次金叉,0,0.06,2,0),COLORFFCC00;
DRAWTEXT(二次金叉,0.2,' 二次金叉'),COLORYELLOW;
A11:=BARSLAST(REF(CROSS(DIF,DEA),1));
底背离:=REF(CLOSE,A11+1)>CLOSE AND DIF>REF(DIF,A11+1) AND CROSS(DIF,DEA);
STICKLINE(底背离,0,0.03,2,0),COLOR00FF00;
DRAWTEXT(底背离,0.12,' 底背离'),COLORFF00FF;
A12:=BARSLAST(REF(CROSS(DEA,DIF),1));
顶背离:=REF(CLOSE,A12+1)<CLOSE AND REF(DIF,A12+1)>DIF AND CROSS(DEA,DIF);
DRAWTEXT(低位金叉 AND 二次金叉 AND 底背离,0.25,'三全项'),COLOR0000FF,LINETHICK2;
VAR4:=MA(CLOSE,13);
VAR5:=100-ABS((CLOSE-VAR4)/VAR4*100);
VAR6:=LLV(LOW,75);
VAR7:=HHV(HIGH,75);
VAR8:=(VAR7-VAR6)/100;
VAR9:=SMA((CLOSE-VAR6)/VAR8,20,1);
VARA:=SMA((OPEN-VAR6)/VAR8,20,1);
VARB:=3*VAR9-2*SMA(VAR9,15,1);
VARC:=3*VARA-2*SMA(VARA,15,1);
VARD:=100-VARC;
VARE:=REF(LOW,1)*0.9;
VARF:=LOW*0.9;
VAR10:=(VARF*VOL+VARE*(CAPITAL-VOL))/CAPITAL;
VAR11:=EMA(VAR10,30);
VAR12:=CLOSE-REF(CLOSE,1);
VAR13:=MAX(VAR12,0);
VAR14:=ABS(VAR12);
VAR15:=SMA(VAR13,7,1)/SMA(VAR14,7,1)*100;
VAR16:=SMA(VAR13,13,1)/SMA(VAR14,13,1)*100;
VAR17:=BARSCOUNT(CLOSE);
VAR18:=SMA(MAX(VAR12,0),6,1)/SMA(ABS(VAR12),6,1)*100;
VAR19:=(-200)*(HHV(HIGH,55)-CLOSE)/(HHV(HIGH,55)-LLV(LOW,55))+100;
VAR1A:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;
VAR1B:=SMA((SMA(VAR1A,4,1)-50)*2,3,1);
VAR1C:=(INDEXC-LLV(INDEXL,14))/(HHV(INDEXH,14)-LLV(INDEXL,14))*100;
源码未完....
下载附件源码....