优化版黄色立体K柱主图公式
RC:=DYNAINFO(3);
S2M:=SMA(C,3,1);
S6:=SMA(C,5,1);
DK:=2*(S2M-S6);
STICKLINE(DK>0,RC,RC+DK,3,0),COLOR660099;
STICKLINE(DK<0,RC,RC+DK,3,0),COLORFF9900;
空头回补:DYNAINFO(54),LINETHICK3;
空头止损:DYNAINFO(56),LINETHICK3;
多头获利:DYNAINFO(53),LINETHICK3;
多头止损:DYNAINFO(55),LINETHICK3;
获利线:COST(50),COLORGREEN,CIRCLEDOT;
A1C:=DATE <= 13181231;
长线启动点:(MA(C,99)) * A1C,POINTDOT,LINETHICK6,COLOR0099FF;
EMA13:=EMA(C,13),COLORWHITE;
EMA21:=EMA(C,21),COLORYELLOW;
EMA34:=EMA(C,34),COLORFF00FF;
EMA60:=MA(C,60),COLORFFCC66;
VAR2:=(2*CLOSE+HIGH+LOW)/4;
VAR3:=IF(YEAR>=2099 AND MONTH>2,0,1);
VAR4:=LLV(LOW,5); VAR5:=HHV(HIGH,4);
散户:=EMA((VAR2-VAR4)/(VAR5-VAR4)*100,4)*VAR3;
庄家:=EMA(0.667*REF(散户,1)+0.333*散户,2)*VAR3;
DRAWTEXT(CROSS(散户,庄家) AND 散户<30,L-0.05,'←低吸'),COLORLIRED;
DRAWTEXT(CROSS(庄家,散户) AND 散户>70,H+0.05,'←高抛'),COLORGREEN;
DRAWICON(CROSS(散户,庄家) AND 散户<30,L-0.05,1);
DRAWICON(CROSS(庄家,散户) AND 散户>70,H+0.05,2);
VAR9:=CLOSE-REF(CLOSE,5);
VARA:=EMA(EMA(VAR9,5),5)/EMA(EMA(ABS(VAR9),5),5);
VARC:=EMA(EMA(VAR9,20),20)/EMA(EMA(ABS(VAR9),20),20);
卖出:=IF(VARA>0 AND CROSS(VARC,VARA),90,100);
DRAWICON(卖出<0,H+0.05,2); 买线:=EMA(CLOSE,2);
卖线:=EMA(SLOPE(CLOSE,21)*20+CLOSE,42);
B1:IF(CROSS(买线,卖线),L-0.02,DRAWNULL),CROSSDOT,LINETHICK3,COLORMAGENTA;
S1:IF(CROSS(80,RSI)*30,H+0.02,DRAWNULL),CROSSDOT,LINETHICK3,COLORYELLOW;
VC:=((CLOSE-MA(CLOSE,6))/MA(CLOSE,6)*100+(CLOSE-MA(CLOSE,24))/MA(CLOSE,24)*100+(CLOSE-MA (CLOSE,32))/MA(CLOSE,32)*100)/3;
S2:=IF(VC>20 AND FILTER(VC< REF(VC,1),5),H+0.02,DRAWNULL),CIRCLEDOT,LINETHICK3,COLORGREEN;
A0:=(L+H+C*2)/4;
A1:EMA(A0,14)COLORBLUE,LINETHICK2;
A2:=EMA(A0,25)COLORLIBLUE,LINETHICK2;
A1X:=(A1-REF(A1,1))/REF(A1,1)*100,NODRAW;
A2X:=(A2-REF(A2,1))/REF(A2,1)*100,NODRAW;
看多:IF(A1X>=0 AND BARSLAST(CROSS(A1X,0))>0,REF((C+O)/2,BARSLAST(CROSS(A1X,0))),DRAWNULL),COLORMAGENTA{,LINETHICK2};
逃顶:IF(A1X<0 AND BARSLAST(CROSS(0,A1X))>0,REF((C+O)/2,BARSLAST(CROSS(0,A1X))),DRAWNULL),COLORCYAN,{LINETHICK2};
买入持股:IF(A1X>=0,A1,DRAWNULL)COLORRED,LINETHICK3;
卖出空仓:IF(A1X<0 AND A2X<0,A1,DRAWNULL)COLORGREEN,LINETHICK3;
AA1:=MA(C,5);
BB1:=MA(C,15);
AF:=CROSS(AA1,BB1);
STICKLINE(AF,LLV(L,4),LLV(L,4),50,1),COLORYELLOW,LINETHICK9;
DRAWTEXT(AF,LLV(L,4),'止损线'),COLORYELLOW;
SR1:=SAR(10,2,10);
IF(CLOSE>SR1,SR1,DRAWNULL),CIRCLEDOT,LINETHICK3,COLOR0000FF;
IF(CLOSE<SR1,SR1,DRAWNULL),CIRCLEDOT,LINETHICK3,COLORGREEN;
ZDF:=(C-REF(C,1))/REF(C,1)*100;
STICKLINE(ZDF>9.8,O,C,5,0),COLORWHITE;
STICKLINE(ZDF<-9.8,O,C,5,0),COLORGREEN;
STICKLINE(C>OPEN,OPEN,C,2.5,0),COLOR0000D5;
STICKLINE(C>OPEN,OPEN,C,0.6,0),COLORCC66FF;
STICKLINE(C<OPEN,OPEN,C,2.5,0),COLORFF6600;
STICKLINE(C<OPEN,OPEN,C,0.6,0),COLORFF9900;
STICKLINE(C/REF(C,1)>1.097,C,O,2.8,0),COLORMAGENTA;
STICKLINE(C/REF(C,1)>1.097,H,L,0.6,0),COLORCC66FF;
STICKLINE(CROSS(A1X,0),H,L,0,0 ),COLOR00FFFF;
STICKLINE(CROSS(A1X,0),C,O,4,0 ),COLOR0066BB;
STICKLINE(CROSS(A1X,0),C,O,3,0 ),COLOR0099CC;
STICKLINE(CROSS(A1X,0),C,O,2,0 ),COLOR00CCEE;
STICKLINE(CROSS(A1X,0),C,O,0.2,0 ),COLOR00FFFF;
STICKLINE(CROSS(0,A1X),L,H,0,0 ),COLOR66CC33;
X1:=(C+L+H)/3;
BB13:=ATAN(EMA(X1,13)-REF(EMA(X1,13),1))*3.1416*10;
EMA8:=EMA(C,8);
DRAWTEXT(FILTER(BB13>1 AND EMA(X1,13)>REF(EMA(X1,8),1),10),
EMA8,'∠45升'),COLORWHITE;
E1:=BARSCOUNT(C);
AH:=HHV(H,200);
AL:=LLV(L,200);
B0:=(AH-AL)/40;
KB1:=H+B0;
KB2:=L-B0;
STICKLINE((E1+0)/34=FLOOR((E1+0)/34),KB2,KB2-0.8*B0,1,0),COLORYELLOW,LINETHICK3;
DRAWTEXT((E1+0)/34=FLOOR((E1+0)/34),KB2-B0,'时窗'),COLORYELLOW;
DRAWICON((ZIG(3,5)>REF(ZIG(3,5),1)) AND (REF(ZIG(3,5),1)<=REF(ZIG(3,5),2)) AND (REF(ZIG(3,5),2)<=REF(ZIG(3,5),3)),LOW*0.98,9) ;
DRAWICON((ZIG(3,5)<REF(ZIG(3,5),1)) AND (REF(ZIG(3,5),1)>=REF(ZIG(3,5),2)) AND (REF(ZIG(3,5),2)>=REF(ZIG(3,5),3)),HIGH*1.01,4);
VAR3Q:=(CLOSE-MA(CLOSE,6))/MA(CLOSE,6)*100;
VAR4Q:=(CLOSE-MA(CLOSE,24))/MA(CLOSE,24)*100;
VAR5Q:=(CLOSE-MA(CLOSE,32))/MA(CLOSE,32)*100;
VAR6Q:=(VAR3Q+VAR4Q+VAR5Q)/3;
VAR7Q:=EMA(VAR6Q,5);
ZB:=EMA(EMA(VAR3Q,5),5)*3, COLORSTICK;
VAR8Q:=IF(VAR6Q<=-20,10,0);
VAR9Q:=HHV(VAR8Q,10);
VARA4:=IF(VAR9Q AND CROSS(MA(CLOSE,3),MA(CLOSE,5)),20,0);
K1:=EMA(VAR7Q,5)*2, , COLORFF00FF;
D1:=EMA(K1,5), , COLORWHITE;
J1:=K1*3-D1*2, ,COLORYELLOW;
VARB4:=BETWEEN(CLOSE,MA(CLOSE,3),MA(CLOSE,5)) AND J1>10;
HS:=VOL/CAPITAL*100, , COLORGREEN;
DRAWTEXT(VAR8Q=10 AND FILTER(VAR8Q=10,5),LOW*1.00,'准备') COLORMAGENTA;
DRAWTEXT(VARA4=20,LOW*1.00,'一定要买') COLOREE82EE;
DRAWICON(VARA4=20,LOW*1.00,1);
VARE4:=MA(100*(CLOSE-LLV(CLOSE,34))/(HHV(HIGH,34)-LLV(LOW,34)),5)-20;
VARF4:=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);
VAR10W:=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);
VAR11W:=VARF4<REF(VAR10W,1) AND VOL>REF(VOL,1) AND CLOSE>REF(CLOSE,1);
DRAWTEXT(VAR11W AND COUNT(VAR11W,30)=1,LOW*0.95,'庄家异动'),LINETHICK1,COLORFF00FF;
VAR12W:=(HIGH+LOW+CLOSE)/3;
VAR13W:=(VAR12W-MA(VAR12W,14))/(0.015*AVEDEV(VAR12W,14));
VAR14W:=(VAR12W-MA(VAR12W,70))/(0.015*AVEDEV(VAR12W,70));
VAR15W:=IF(VAR13W>=150 AND VAR13W<200 AND VAR14W>=150 AND VAR14W<200,10,0);
VAR16W:=IF(VAR13W<=-150 AND VAR13W>-200 AND VAR14W<=-150 AND VAR14W>-200,-10,VAR15W);
VAR17W:=(CLOSE-MA(CLOSE,13))/MA(CLOSE,13)*100;
VAR18W:=100-ABS(VAR17W);
VAR19W:=IF(VAR18W<90,VAR18W,100);
VAR1A1:=IF(VARE4>0,VARE4,0);
VAR1B1:=IF(VAR14W>=200 AND VAR13W>=150,15,IF(VAR14W<=-200 AND VAR13W<=-150,-15,VAR16W))+60;
VAR1C1:=VAR1A1>48 AND VAR1B1>60 AND VAR19W<100;
DRAWTEXT(VAR1C1 AND COUNT(VAR1C1,30)=1,LOW*1.00,'大动作') COLORYELLOW;
VAR20W:=PEAKBARS(3,15,1)<10;
VAR21W:=IF(VAR20W=1,2,0);
VAR22W:=IF(VAR21W=2,2,0);
VAR23W:=IF(VAR22W>REF(VAR22W,1),35,0)LINETHICK2;
DRAWTEXT(VAR23W=35,HIGH*1.00,'一定要逃')COLORGREEN;
DRAWICON(VAR23W=35,HIGH*1.00,2);
636344595.jpg
|