MACD_吸拉派落主圖}
DRAWGBK(O>C,RGB(48,41,124),RGB(0,0,0),0,'',0);
ZF:=STRCAT(STRCAT(STRCAT(STRCAT(STRCAT(STRCAT(DYBLOCK,'
DRAWTEXT_FIX(ISLASTBAR,0,0,0,ZF),{COLORYELLOW}COLOR008888;
{四區(qū)背景主圖}
N:=120;
M:=BARSLAST(CURRBARSCOUNT=N);
GD:=CONST(IF(ISLASTBAR=1,HHV(H,M),0));
DD:=CONST(IF(ISLASTBAR=1,LLV(L,M),0));
KJ:=GD-DD;
高區(qū):IF(CURRBARSCOUNT<=N,GD,DRAWNULL),LINETHICK1,COLOR004080;
低區(qū):IF(CURRBARSCOUNT<=N,DD,DRAWNULL),LINETHICK1,COLOR004080;
平衡:IF(CURRBARSCOUNT<=N,DD+KJ/2,DRAWNULL),LINETHICK1,COLOR004080;
支撐0:IF(CURRBARSCOUNT<=N/2,DD+KJ*0.191,DRAWNULL),LINETHICK1,COLOR004080;
強(qiáng)勢:IF(CURRBARSCOUNT<=N/2,DD+KJ*0.382,DRAWNULL),LINETHICK1,COLOR004080;
突破:IF(CURRBARSCOUNT<=N,DD+KJ/2,DRAWNULL),LINETHICK1,COLOR004080;
警示:IF(CURRBARSCOUNT<=N/2,DD+KJ*0.618,DRAWNULL),LINETHICK1,COLOR004080;
壓力:IF(CURRBARSCOUNT<=N/2,DD+KJ*0.809,DRAWNULL),LINETHICK1,COLOR004080;
CD:=CURRBARSCOUNT,NODRAW;
STICKLINE(CD=60,HHV(高區(qū),60),LLV(低區(qū),60),0,1),COLOR004080;{0.01}
STICKLINE(CD=120,HHV(高區(qū),60),LLV(低區(qū),60),0,1),COLOR004080;
STICKLINE(CD=1,HHV(高區(qū),60),LLV(低區(qū),60),0,1),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=1,壓力,'壓力'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=1,警示,'警示'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=1,突破,'突破'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=1,強(qiáng)勢,'強(qiáng)勢'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=1,支撐0,'支撐'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+30,GD-KJ*0.09,'【風(fēng)險(xiǎn)區(qū)】--高拋避險(xiǎn)'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+30,GD-KJ*0.3,'【警示區(qū)】--逢高減倉'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+30,GD-KJ*0.45,'【突破區(qū)】--主力拉升'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+30,GD-KJ*0.55,'【拉升區(qū)】--強(qiáng)勢畜銳'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+30,DD+KJ/3,'【關(guān)注區(qū)】--逢低買入'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+30,DD+KJ/10,'【低吸區(qū)】--大膽買入'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/2+6,GD-KJ*0.25,'【拉升區(qū)】'),COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/2+6,DD+KJ*0.25,'【持股區(qū)】'),COLOR004080;
DRAWKLINE(HIGH,OPEN,LOW,CLOSE);
{吸拉派落主圖}
DIFF:=EMA(C,12) - EMA(C,26);
DEA:=EMA(DIFF,9);
MACD:=2*(DIFF-DEA);
M價(jià):(REF(MACD,1)/2 +(26-1)*REF( EMA(C,26),1)/(26+1)
-(12-1)*REF( EMA(C,12),1)/(12+1)+ 2*DIFF/(9+1)
+(9-1)*REF( DEA,1)/(9+1)) /2/(1 /(12+1)-1/(26+1)),DOTLINE;
WDIF:=EMA(EMA(EMA(C,3),3),3)+DIFF;
WDEA9:EMA(WDIF,9),{COLORGREEN.COLORYELLOW}COLOR008888,LINETHICK2;
MA60:=MA(CLOSE,60),COLORLIGRAY;
吸:XLPL.NOTEXT吸,NODRAW;
拉:XLPL.NOTEXT拉,NODRAW;
派:XLPL.NOTEXT派,NODRAW;
落:XLPL.NOTEXT落,NODRAW;
AAW:IF( 吸!=DRAWNULL, M價(jià),DRAWNULL),COLORLIRED,LINETHICK2;
BBW:IF( 拉!=DRAWNULL,M價(jià),DRAWNULL),{COLORRED}COLOR0099FF,LINETHICK2;
CCW:IF( 派!=DRAWNULL,M價(jià),DRAWNULL),{COLORGREEN}COLORCYAN,LINETHICK2;
DDW:IF( 落!=DRAWNULL,M價(jià),DRAWNULL),{COLORWHITE}COLORAAAAAA,LINETHICK2;
STICKLINE(AAW,LOW,HIGH,0,0),COLORLIRED;
STICKLINE(AAW,C,O,3,1),COLORLIRED;
STICKLINE(BBW,LOW,HIGH,0,0),{COLORRED}COLOR0099FF;
STICKLINE(BBW ,C,O,3,1),{COLORRED}COLOR0099FF;
STICKLINE(CCW,LOW,HIGH,0,0),{COLORGREEN}COLORCYAN;
STICKLINE(CCW,C,O,3,1){COLORGREEN}COLORCYAN;
STICKLINE(DDW,LOW,HIGH,0,0),{COLORWHITE}COLORAAAAAA;
STICKLINE(DDW,C,O,3,1),{COLORWHITE}COLORAAAAAA;
DRAWTEXT("KDJ.J"-REF("KDJ.J",1)>30
ANDEXPMA(C,12)>EXPMA(C,50),L*0.995,'↖起爆'),{COLORWHITE}COLORAAAAAA;
{---------------}
MA5:MA(CLOSE,5),NODRAW,COLORWHITE;
MA10:MA(CLOSE,10),NODRAW,COLORWHITE;
MA20:MA(CLOSE,20),NODRAW,COLORWHITE;
STICKLINE(CURRBARSCOUNT=1,MA5,MA5,20,1),{COLOR00009C}COLORRED,LINETHICK1;
STICKLINE(CURRBARSCOUNT=1,MA10,MA10,20,1),COLORYELLOW{COLOR008888},LINETHICK2;
DRAWTEXT(ISLASTBAR=1,MA5,'
DRAWTEXT(ISLASTBAR=1,MA10,'
{布林}
M0:=20; P:=10;
BC1:=IF(L=LLV(L,10*P),L,DRAWNULL);
BC2:=CONST(BARSLAST(BC1!=DRAWNULL));
BC3:=IF(BC2=0,L,REF(L,BC2));
TC1:=IF(H=HHV(H,10*P),H,DRAWNULL);
TC2:=CONST(BARSLAST(TC1!=DRAWNULL));
TC3:=IF(TC2=0,H,REF(H,TC2));
BZ:=MAX(BC2,TC2);
高:=IF(CURRBARSCOUNT<=BZ+1,CONST(TC3),DRAWNULL);
低:=IF(CURRBARSCOUNT<=BZ+1,CONST(BC3),DRAWNULL);
MID:=MA(C,M0);
VART1:=POW((C-MID),2);
VART2:=MA(VART1,M0);
VART3:=SQRT(VART2);
U_R:=MID+2*VART3;
L_R:=MID-2*VART3;
BOLL:=IF(ISLASTBAR,REF(MID,1),DRAWNULL);{COLOR333339,LINETHICK2}
UB:=IF(ISLASTBAR,REF(U_R,1),DRAWNULL);
LB:=IF(ISLASTBAR,REF(L_R,1),DRAWNULL);
DRAWTEXT(ISLASTBAR,BOLL,'
DRAWTEXT(ISLASTBAR,IF(ISLASTBAR AND UB<=高, UB,DRAWNULL),'
DRAWTEXT(ISLASTBAR,IF(ISLASTBAR AND LB>=低, LB,DRAWNULL),'
C0:STICKLINE(CURRBARSCOUNT=1,C,C,10000,1),COLOR555555,LINETHICK1;
{中期趨勢回歸劃線}
UR:=6;
LR:=UR;
{ TC1:=IF(H=HHV(H,8*UR),H,DRAWNULL);
TC2:=CONST(BARSLAST(TC1=H))+1;}
UPPER:=CONST(IF(TC2=1,H,REF(H,TC2-1)));
{ BC1:=IF(L=LLV(L,8*LR),L,DRAWNULL);
BC2:=CONST(BARSLAST(BC1=L))+1;}
LOWER:=CONST(IF(BC2=1,L,REF(L,BC2-1)));
LP:=CURRBARSCOUNT<=BC2 AND L=LOWER;{低點(diǎn)定位}
HP:=CURRBARSCOUNT<=TC2 AND H=UPPER;{高點(diǎn)定位}
{STICKLINE(IF(BC2>TC2,HP,LP),LOWER,UPPER,0,0),COLOR628962;
STICKLINE(IF(BC2>TC2,LP,HP),LOWER,UPPER,0,0),COLOR628962;}
NOD:=(IF(TC2>BC2,TC2,BC2)-IF(TC2>BC2,BC2,TC2));{用時(shí)};
LR1:=FORCAST(C,NOD+1);
NP:=IF(CURRBARSCOUNT<=MAX(BC2,TC2),CONST(IF(MIN(TC2,BC2)=1,LR1,REF(LR1,MIN(TC2,BC2)-1))),DRAWNULL),POINTDOT,COLOR93BDA8;{近點(diǎn)=}
LR2:=SLOPE(C,NOD+1);
LR3:=CONST(IF(MIN(TC2,BC2)=1,LR2,REF(LR2,MIN(TC2,BC2)-1)));
FP:=NP-LR3*(NOD),POINTDOT,COLOR93BDA8;{遠(yuǎn)點(diǎn)=}
EQU:=(NP+FP)/2,POINTDOT,COLOR93BDA8;{=}
AD:=ABS(NP-FP);{高差}
DBL:=BARSLAST(BC1!=DRAWNULL)+1;
DBH:=BARSLAST(TC1!=DRAWNULL)+1;
BSP:=IF(BC2>TC2,DBL,DBH)-1;
LRL:=IF(NP>FP,FP+AD/NOD*BSP,FP-AD/NOD*BSP);
AT1:=IF(BETWEEN(CURRBARSCOUNT,BC2,TC2) ANDH>LRL,H,LRL);
AT2:=HHV(AT1-LRL,MAX(BC2,TC2));
AT3:=CONST(BARSLAST(AT1-LRL=AT2));
AT4:=CONST(IF(AT3=0,H,REF(H,AT3)));
AT5:=CONST(IF(AT3=0,AT1-LRL,REF(AT1-LRL,AT3)));
ATL:=LRL+AT5;
UT1:=IF(BETWEEN(CURRBARSCOUNT,BC2,TC2) AND L
UT2:=HHV(LRL-UT1,MAX(BC2,TC2));
UT3:=CONST(BARSLAST(LRL-UT1=UT2));
UT4:=CONST(IF(UT3=0,H,REF(H,UT3)));
UT5:=CONST(IF(UT3=0,LRL-UT1,REF(LRL-UT1,UT3)));
UTL:=LRL-UT5;
RH:=IF(CURRBARSCOUNT>=MIN(BC2,TC2)-10,ATL,CONST(REF(ATL,MIN(BC2,TC2)-11)));{限制高}
RL:=IF(CURRBARSCOUNT>=MIN(BC2,TC2)-10,UTL,CONST(REF(UTL,MIN(BC2,TC2)-11)));{限制低}
中期中軌:IF(NP>FP,IF(LRL<=RH,LRL,DRAWNULL),IF(LRL>=RL,LRL,DRAWNULL)),COLOR628962;
中期上軌:IF(NP>FP,IF(ATL<=RH,ATL,DRAWNULL),IF(ATL>=RL,ATL,DRAWNULL)),COLOR628962;
中期下軌:IF(NP>FP,IF(UTL<=RH,UTL,DRAWNULL),IF(UTL>=RL,UTL,DRAWNULL)),COLOR628962;
止損:0.965*REF(H,1),LINETHICK0;{,DRAWNULL,COLORWHITE}
止盈:1.06*REF(H,1),LINETHICK0;
==========================================================
{波段王,中長期個(gè)股趨勢背景,底部
VAR21:=(INDEXC+INDEXH+INDEXL+INDEXO)/4;
VAR22:=SUMBARS(VOL,CAPITAL);
VAR23:=HHV(VAR21,VAR22);
VAR24:=LLV(VAR21,VAR22);
VAR25:=(2*VAR21-VAR24-REF(VAR24,1))/(VAR23-VAR24);
VAR26:=(VAR21-VAR24)/(VAR23-VAR24);
VAR27:=IF(VAR21<=VAR24,VAR25*60,VAR26*60);
VAR28:=600*(EMA(CLOSE,3)-EMA(LOW,30))/EMA(LOW,30);
VAR29:=EMA(VAR28,7);
VAR2A:=(WINNER(120*CLOSE/100)-WINNER(100*CLOSE/100))*100;
VAR2B:=(-100)*(WINNER(120*CLOSE/100)-WINNER(100*CLOSE/100))+5;
VAR2C:=HHV(HIGH,9)-LLV(LOW,9);
VAR2D:=HHV(HIGH,9)-CLOSE;
VAR2E:=CLOSE-LLV(LOW,9);
VAR2F:=VAR2D/VAR2C*100-70;
VAR210:=(CLOSE-LLV(LOW,60))/(HHV(HIGH,60)-LLV(LOW,60))*100;
VAR211:=(2*CLOSE+HIGH+LOW)/4;
VAR212:=SMA(VAR2E/VAR2C*100,3,1);
VAR213:=LLV(LOW,34);
VAR214:=SMA(VAR212,3,1)-SMA(VAR2F,9,1);
VAR215:=IF(VAR214>100,VAR214-100,0);
VAR216:=HHV(HIGH,34);
VAR217:=EMA((VAR211-VAR213)/(VAR216-VAR213)*100,8);
VAR218:=EMA(VAR217,5);
STICKLINE(VAR217-VAR218>0,5,12.5,4.2,0), ,{COLORRED}COLOR0099FF; {COLORCYAN}
STICKLINE(VAR217-VAR218<0,5,12.5,4.2,0),,{COLORGREEN}COLORFFFF00 ;
DRAWTEXT(CURRBARSCOUNT=1,8.5,'_安全區(qū)'),{COLORMAGENTA}COLOR0099FF;{超賣安全區(qū)}
{治勢能臣動力線}
動力線:=EMA((C-LLV(LOW,10))/(HHV(HIGH,25)-LLV(LOW,10))*100,4),LINETHICK2,{COLORWHITE}COLOR008888;
{短線驍騎吸籌值}
XVAR2:=REF(LOW,1);
XVAR3:=SMA(ABS(LOW-XVAR2),3,1)/SMA(MAX(LOW-XVAR2,0),3,1)*100;
XVAR4:=EMA(IF(CLOSE*1.3,XVAR3*10,XVAR3/10),3);
XVAR5:=LLV(LOW,13);
XVAR6:=HHV(XVAR4,13);
XVAR7:=IF(MA(CLOSE,34),1,0);
XVAR8:=EMA(IF(LOW<=XVAR5,(XVAR4+XVAR6*2)/2,0),3)/618*XVAR7;
XVAR9:=IF(XVAR8>100,100,XVAR8)*0.675+12.5;
STICKLINE(XVAR9>-120,12.5,XVAR9,8,1),COLORYELLOW;
{};
MA1:=5;M2:=10;M3:=30;M4:=60;
J1:=ATAN((MA(C,MA1)/REF(MA(C,MA1),1)-1)*100)*180/3.1416;
J2:=ATAN((MA(C,M2)/REF(MA(C,M2),1)-1)*100)*180/3.1416;
J3:=ATAN((MA(C,M3)/REF(MA(C,M3),1)-1)*100)*180/3.1416;
J4:=ATAN((MA(C,M4)/REF(MA(C,M4),1)-1)*100)*180/3.1416;
均線5:=J1;
均線10:=J2;
均線30:=J3;
均線60:=J4;
XG1:=J1>=0 AND 0>=REF(0,1);
XG2:=J2>=0 AND 0>=REF(0,1);
XG3:=J3>=0 AND 0>=REF(0,1);
XGX:=CROSS(XG1,XG2);
XGY:=CROSS((XG1,XG2),XG3);
低買1:IF(XGX,55.5,12),COLOR0099FF{COLORYELLOW},LINETHICK2;{右側(cè)買};
低買2:IF(XGY,55.5,12),COLORLIRED{COLORYELLOW},LINETHICK2;{右側(cè)買};
N:=9;M01:=3;M02:=3;
RSV:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;
K:SMA(RSV,M01,1),COLORCYAN;
D:SMA(K,M02,1),COLOR008888;
J:3*K-2*D,COLORAAAAAA;
聯(lián)系客服