N:=5;
P:=12;
GJ:=(C+H+L+O)/4;
bbi:(MA(CLOSE,3)+MA(CLOSE,6)+MA(CLOSE,12)+MA(CLOSE,24))/4;
明日阻力:=L+(GJ-L)+(C-L);
明日支撑:=L+(C-GJ);
UPR:BBI+P*STD(BBI,N);
DWN:BBI-P*STD(BBI,N);
下档线:=(((CLOSE - LLV(LOW,13)) / (HHV(HIGH,13) - LLV(LOW,13))) * 100);
RRRSV:=SMA(下档线,3,1);
KKK:=SMA(RRRSV,3,1);
DDDDD:=((3 * RRRSV) - (2 * KKK));
JJ12:=(((CLOSE - LLV(LOW,55)) / (HHV(HIGH,55) - LLV(LOW,55))) * 100);
RSV24:=SMA(JJ12,3,1);
K24:=SMA(RSV24,3,1);
D24:=((3 * RSV24) - (2 * K24));
VARQ3:=(CLOSE-MA(CLOSE,6))/MA(CLOSE,6)*100;
VARQ4:=(CLOSE-MA(CLOSE,24))/MA(CLOSE,24)*100;
VARQ5:=(CLOSE-MA(CLOSE,32))/MA(CLOSE,32)*100;
VARQ6:=(VARQ3+VARQ4+VARQ5)/3;
VARQ7:=EMA(VARQ6,5);
压力2:=IF(crOSS(D24,DDDDD),HIGH,REF(HIGH,BArslAST(CROSS(D24,DDDDD)))),COLORFFFFFF;
底部:=LLV(HIGH,30),COLOR00FF00;
今日阻力:REF(明日阻力, 1),NODRAW;
今日支撑:REF(明日支撑, 1),NODRAW;
ZB:=EMA(EMA(VARQ3,5),5)*3, COLORSTICK;
VARQ8:=IF(VARQ6<=-20,10,0);
VARQ9:=HHV(VARQ8,10);
压力位:IF(ISLASTBAR,压力2,DRAWNULL),NODRAW;
底部位:IF(ISLASTBAR,底部,DRAWNULL),NODRAW;
高:=REF(HHV(H,80),3);
低:=REF(LLV(L,80),3);
VARQA:=IF(VARQ9 AND CROSS(MA(CLOSE,3),MA(CLOSE,5)),20,0);
K:=EMA(VARQ7,5)*2, , COLORFF00FF;
D:=EMA(K,5), , COLORWHITE;
J:=K*3-D*2, ,COLORYELLOW;
H19:=高-(高-低)*0.191;
H38:=高-(高-低)*0.382;
H中:=高-(高-低)*0.5;
H61:=高-(高-低)*0.618;
H80:=高-(高-低)*0.809;
VARQB:=BETWEEN(CLOSE,MA(CLOSE,3),MA(CLOSE,5)) AND J>10;
HS:=vol/CAPITAL*100, , COLORGREEN;
DRAWTEXT(VARQ8=10 AND FILTER(VARQ8=10,5),LOW*0.93,'接近底部') COLORMAGENTA;
顶点:REFDATE(高,DATE),POINTDOT,COLORWHITE;
疯牛19.8:REFDATE(H19,DATE),POINTDOT,COLORYELLOW;
突破38.2:REFDATE(H38,DATE),POINTDOT,COLORMAGENTA;
平衡50:REFDATE(H中,DATE),POINTDOT,COLORRED;
回落61.8:REFDATE(H61,DATE),POINTDOT,COLORGREEN;
安全80.9:REFDATE(H80,DATE),POINTDOT,COLORBLUE;
低点:REFDATE(低,DATE),POINTDOT,COLORWHITE;
DRAWTEXT(VARQA=20,LOW*0.95,'底部') COLORYELLOW;
DRAWTEXT(ISLASTBAR,顶点,'顶点'),COLORWHITE;
DRAWTEXT(ISLASTBAR,疯牛19.8,'疯牛'),COLORYELLOW;
DRAWTEXT(ISLASTBAR,突破38.2,'突破'),COLORMAGENTA;
DRAWTEXT(ISLASTBAR,平衡50,'平衡'),COLORRED;
DRAWTEXT(ISLASTBAR,回落61.8,'回落'),COLORMAGENTA;
VARQE:=MA(100*(CLOSE-LLV(CLOSE,34))/(HHV(HIGH,34)-LLV(LOW,34)),5)-20;
VARQF:=100-3*SMA((CLOSE-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,
1)+2*SMA(SMA((CLOSE-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1),15,1);
VAR1:=CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2);
VAR2:=REF(VAR1,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR3:=REF(VAR2,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR4:=REF(VAR3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR5:=REF(VAR4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR6:=REF(VAR5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR7:=REF(VAR6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR8:=REF(VAR7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR9:=REF(VAR8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARQ10:=100-3*SMA((OPEN-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,
1)+2*SMA(SMA((OPEN-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1),15,1);
VARQ11:=VARQF<REF(VARQ10,1) AND VOL>REF(VOL,1) AND CLOSE>REF(CLOSE,1);
DRAWTEXT(VARQ11 AND COUNT(VARQ11,30)=1,LOW*0.95,'大资金活动'),LINETHICK1,COLORFF00FF;
VARQ12:=(HIGH+LOW+CLOSE)/3;
VARQ13:=(VARQ12-MA(VARQ12,14))/(0.015*AVEDEV(VARQ12,14));
VARQ14:=(VARQ12-MA(VARQ12,70))/(0.015*AVEDEV(VARQ12,70));
VARA:=REF(VAR9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VARB:=REF(VARA,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARC:=REF(VARB,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VARD:=CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2);
VARE:=REF(VARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARF:=REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR10:=REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR11:=REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR12:=REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR13:=REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR14:=REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR15:=REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR16:=REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR17:=REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR18:=REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR19:=REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13
OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1) AND VAR1;
VARQ15:=IF(VARQ13>=150 AND VARQ13<200 AND VARQ14>=150 AND VARQ14<200,10,0);
VARQ16:=IF(VARQ13<=-150 AND VARQ13>-200 AND VARQ14<=-150 AND VARQ14>-200,-10,VARQ15);
VARQ17:=(CLOSE-MA(CLOSE,13))/MA(CLOSE,13)*100;
VARQ18:=100-Abs(VARQ17);
VARQ19:=IF(VARQ18<90,VARQ18,100);
DRAWICON(VAR19,L*0.98,1);
DRAWICON(CROSS(LLV(AMOUNT/V/100,3),L) AND V>REF(V,3) AND C<O,O*1.1,2);
MA6:EMA(C,6),LINETHICK2,COLORFFFF00;
MA18:EMA(C,18),LINETHICK2,COLOR00FF00;
DRAWBAND(MA6,RGB(155,50,50),MA18,RGB(0,100,50));
VARQ1A:=IF(VARQE>0,VARQE,0);
VARQ1B:=IF(VARQ14>=200 AND VARQ13>=150,15,IF(VARQ14<=-200 AND VARQ13<=-150,-15,VARQ16))+60;
VARQ1C:=VARQ1A>48 AND VARQ1B>60 AND VARQ19<100;
WWWGUPANGCOM:=(((CLOSE -LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9)))* 100);
中:STICKLINE(MA6<MA18 AND MA6>REF(MA6,1) AND MA18<=REF(MA18,1),MA6,MA18,0.3,0),COLORCYAN;
长:STICKLINE(MA6>MA18 AND MA6>REF(MA6,1) AND MA18<=REF(MA18,1),MA6,MA18,0.3,0),COLORMAGENTA;
线:STICKLINE(MA6<MA18 AND MA6<REF(MA6,1) AND MA18>=REF(MA18,1),MA6,MA18,0.3,0),COLORBLUE;
买进:=CROSS(MA6,MA18) AND MA18>=REF(MA18,1);
DRAWICON(买进,L*0.95,9);
DRAWTEXT(CROSS(85,rsi),(HIGH * 1.02),'落袋'),COLORCYAN;
DRAWTEXT(VARQ1C AND COUNT(VARQ1C,30)=1,LOW*0.95,'大笔成交') COLORWHITE;