{范一再精改源码}
DIRECTION:=ABS(CLOSE-REF(C,10));
VOLATILITY:=SUM(ABS(CLOSE-REF(C,1)),10);
ER:=DIRECTION/VOLATILITY;
FASTEST:=2/3;
SLOWEST:=2/30;
SMOOTH:=ER*(FASTEST-SLOWEST)+SLOWEST;
SC:=POW(SMOOTH,2);
范:=DMA(C,SC),COLORMAGENTA,LINETHICK1;
范一:DMA(C,SC)+2*STD(DMA(C,SC),4),COLORRED,LINETHICK2;
DRAWTEXT(ISLASTBAR,范一,STRCAT(' 范一线上强:',CON2STR(范一,2))),COLORRED;
操作:=MA(C,3);
界:HHV(操作,15),LINETHICK1,COLORLIGREEN,DOTLINE;
DRAWTEXT(ISLASTBAR,界,STRCAT(' 减仓界:',CON2STR(界,2))),COLORLIGREEN;
STICKLINE(CROSS(界,C),C,O,3.4,0),COLORLIGREEN;
STICKLINE(CROSS(界,C),H,L,0.01,0),COLORLIGREEN;
DRAWTEXT(CROSS(界,C),H*1.015,'少&卖&点'),COLORLIGREEN;
ZLCM:=EMA(WINNER(CLOSE)*70,3);
SHCM:=EMA((WINNER(CLOSE*1.1)-WINNER(CLOSE*0.9))*80,3);
ZSHTL:=SHCM/(ZLCM+SHCM)*100;
ZZLKP:=ZLCM/(ZLCM+SHCM)*100;
ZCMZL:=MA(ZLCM+SHCM,13);
ZZNTS:=BARSLAST(ZSHTL<90 AND REF(ZSHTL,1)>90);
ZSHJJ:=EMA(ZSHTL,89);
ZZLJJ:=EMA(ZZLKP,89);
DKB:=IF(ZZLKP-REF(ZZLKP,1)>ZSHTL-REF(ZSHTL,1),1,0);
RSVB:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;
KK1:=SMA(RSVB,10,1);
D1:=SMA(KK1,5,1);
KK:=INTPART(KK1);
DDB:=INTPART(D1);
TFXXS:=KK+DDB;
T1:=CONST( ZCMZL>REF(ZCMZL,1) AND DKB=1);
T2:=CONST( ZCMZL>REF(ZCMZL,1) AND DKB=0);
T3:=CONST( ZCMZL=REF(ZCMZL,1));
T4:=CONST( ZCMZL<REF(ZCMZL,1) AND DKB=1);
T5:=CONST( ZCMZL<REF(ZCMZL,1) AND DKB=0);
T12:=CONST( ZSHTL>90 );
T13:=CONST( ZZLKP>75 );
T14:=CONST(CROSS(ZCMZL,ZZLJJ) AND ZZLKP>ZZLJJ AND ZZLKP>10 AND ZZLJJ>REF(ZZLJJ,1) AND ZCMZL>REF(ZCMZL,1) );
T15:=CONST(CROSS(ZCMZL,ZZLKP) AND ZZLKP>ZZLJJ AND ZZLKP<ZSHTL AND ZZLKP>10 AND ZZLJJ>REF(ZZLJJ,1) AND ZCMZL>REF(ZCMZL,1) );
T16:=CONST( CROSS(ZCMZL,ZSHTL) AND ZSHTL>ZZLKP AND ZCMZL>REF(ZCMZL,1));
T17:=CONST( CROSS(ZCMZL,100) AND ZCMZL>REF(ZCMZL,1));
T18:=CONST(REF(ZSHTL,1)>90 AND ZSHTL<90 );
DRAWTEXT_FIX(T1 ,0.87,0.4,0,'监控:主力增仓'),COLOR8080FF;
DRAWTEXT_FIX(T2 ,0.85,0.4,0,'监控:主力减仓'),COLORFFFF00;
DRAWTEXT_FIX(T3 ,0.85,0.4,0,'监控:多空平衡'),COLORGRAY;
DRAWTEXT_FIX(T4 ,0.85,0.4,0,'监控:主力回补'),COLORFF9933;
DRAWTEXT_FIX(T5 ,0.85,0.4,0,'监控:主力出逃'),COLORFFFF00;
DRAWTEXT_FIX(T12,0.84,0.36,0,'提示:筑底散兵坑 '),COLOR66FFCC;
DRAWTEXT_FIX(T13,0.84,0.36,0,'提示:铸顶风险区'),COLORFFFF00;
DRAWTEXT_FIX(T14,0.84,0.36,0,'提示:穿越主力 '),COLOR8080FF;
DRAWTEXT_FIX(T15,0.84,0.36,0,'提示:穿越主力 '),COLORYELLOW;
DRAWTEXT_FIX(T16,0.84,0.36,0,'提示:穿越散户 '),COLORGREEN;
DRAWTEXT_FIX(T17,0.84,0.36,0,'提示:全盘穿越 '),COLOR3399FF;
DRAWTEXT_FIX(T18,0.84,0.36,0,'提示:神秘黑洞 '),COLOR9966FF;
MID:=(3*CLOSE+LOW+OPEN+HIGH)/6;
WH1:=IF(L=LLV(L,9),L,0);
WH2:=CONST(BARSLAST(WH1!=0));
WH3:=CONST(IF(WH2=0,H,REF(H,WH2)));
WH4:=CONST(REF(BARSLAST(H>WH3),WH2+1)+WH2+1);
WH5:=CONST(IF(WH4=0,H,REF(H,WH4)));
WH6:=CONST(REF(BARSLAST(H>WH5),WH4+1)+WH4+1);
WH7:IF(CURRBARSCOUNT<=WH2+10,CONST(IF(WH6=0,H,REF(H,WH6))),DRAWNULL),COLORYELLOW,DOTLINE;
DRAWTEXT(ISLASTBAR,WH7,STRCAT('可进场线:',CON2STR(WH7,2))),COLORYELLOW;