三套做短线的主副图指标公式
1、百战百胜+短线高手
2、逃顶+短线黑马
3、短线波段王+发财树
百战百胜+短线高手
主图指标一般在一个波段给出提示,幅图根据量价迅速给出资金动向。结合起来就可以玩转活跃股票的波段了。此指标不适合在活跃度不好的股票。
p1 1 300 7 p2 1 300 21 p3 1 300 250
MA1:EMA(CLOSE,P1),COLORWHITE,LINETHICK3;
MA2:EMA(CLOSE,P2),COLORRED,LINETHICK2;
MA3:EMA(CLOSE,P3),COLORYELLOW;
工作线: EMA(CLOSE,P1),COLORWHITE,LINETHICK3;
神秘线: EMA(CLOSE,P2),COLORRED,LINETHICK3;
生命线: EMA(CLOSE,P3),COLORYELLOW;
DRAWTEXT(CROSS(工作线,神秘线),工作线,'★建仓') ,COLORYELLOW;
DRAWTEXT(CROSS(神秘线,工作线),神秘线,'★空仓') ,COLORGREEN;
LC:=REF(CLOSE,3);
JH:=SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100;
DRAWTEXT(FILTER(CROSS(JH,30),55),LOW*0.98,'↑关注'),COLORYELLOW,LINETHICK1;
DRAWTEXT(FILTER(CROSS(84,JH),22),HIGH*1.02,'↓小心'),COLOR00FF00;
幅图
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 散户<50 AND 29<散户,20,'短快进'),COLOR00FF00;
DRAWTEXT(CROSS(庄家,散户) AND 散户>40 AND 71>散户,50,'短快出'),COLOR00FFFF;
DRAWTEXT(CROSS(散户,庄家) AND 散户<30,0,'逢低吸'),COLOR3399CC;
DRAWTEXT(CROSS(庄家,散户) AND 散户>70,75,'逢高减'),COLORFFFF33;
DRAWICON(CROSS(散户,庄家) AND 散户<30,20,1);
DRAWICON(CROSS(庄家,散户) AND 散户>70,80,2);
VAR9:=CLOSE-REF(CLOSE,5);
VARA:=EMA(EMA(VAR9,5),5)/EMA(EMA(ABS(VAR9),5),5)*100;
VARC:=EMA(EMA(VAR9,20),20)/EMA(EMA(ABS(VAR9),20),20)*100;
卖出: IF(VARA>0 AND CROSS(VARC,VARA),90,100);
DRAWTEXT(VARA>0 AND CROSS(VARC,VARA),90,'中线逃吧!'),COLOR0033FF;
DRAWICON(卖出<0,100,2);
逃顶+短线黑马
主图用于逃顶,幅图用于短线抄底。
(N 1 2 10)
MA5:MA(C,5),COLORWHITE;
MA10:MA(C,10),COLORFF00FF;
MA20:MA(C,20),COLOR00FF00;
MA30:MA(C,30),COLORYELLOW;
MA120:SMA(C,120,1),COLOR0000FF;
ZH520:=ABS(MA5-MA20)/MA20*100<=N;
ZH530:=ABS(MA5-MA30)/MA30*100<=N;
QSXS1:=MA5>REF(MA5,1);
QSXS2:=MA20>REF(MA20,1);
QSXS3:=MA30>REF(MA30,1);
DTPL:=MA20>MA30 AND MA30>MA120;
LYHT:=DTPL AND QSXS2 AND QSXS3 AND NOT(QSXS1) AND REF(QSXS1,1);
老鸭回头:=LYHT*50,COLORFF00FF,POINTDOT;
WR5:=100*(HHV(H,5)-C)/(HHV(H,5)-LLV(L,5));
WR6:=100*(HHV(H,6)-C)/(HHV(H,6)-LLV(L,6));
WR:=80-(WR5*3+WR6*2)/5,COLORYELLOW,POINTDOT;
坑:=IF(WR<0,WR,0),COLORYELLOW;
LYT:=DTPL AND QSXS2 AND QSXS3 AND COUNT(QSXS1,4)<=1;
GJHS:=C>MA5 AND ((QSXS1 AND NOT(REF(QSXS1,1))) OR C>REF(C,3));
LYKK:=GJHS AND (ZH520 OR ZH530) AND LYT;
买:=(LYKK AND NOT(REF(LYKK,1)))*50,COLOR00FF00,POINTDOT,LINETHICK2;
优选:=(买 AND COUNT((MA10>MA20),5)=5)*100,COLORYELLOW,POINTDOT,LINETHICK2;
{以下设置主图显示方式}
DRAWTEXT(老鸭回头,(MA10+MA20)/2, ''),COLORFF00FF;
DRAWTEXT(老鸭回头,(MA10+MA20)/2, ''),COLORFF00FF;
DRAWTEXT(WR<0,L*0.99, ''),COLORYELLOW;
DRAWTEXT(WR<-10,L*0.99, ''),COLORWHITE;
STICKLINE(买,H,L,0,1),COLOR00FF00,LINETHICK2;
STICKLINE(买,O,C,4,1),COLOR00FF00,LINETHICK2;
DRAWTEXT(买,L*0.99, '买买'),COLOR00FF00;
DRAWICON(优选,L*0.99,1);
{以下设置逃顶指标}
VARC:=SMA(MAX(C-REF(C,1),0),6,1)/SMA(ABS(C-REF(C,1)),6,1)*100;
DRAWICON(CROSS(82,VARC),HIGH,2);
VAR6:=REF(C,1);
VAR7:=SMA(MAX(C-VAR6,0),6,1)/SMA(ABS(C-VAR6),6,1)*100;
DRAWTEXT(CROSS(84,VAR7),H*1.01,'逃顶'),COLORYELLOW ;
幅图
A1:3*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1)-2*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1);
黑马线:EMA(A1,5),LINETHICK2,COLOR6600FF;
A2:=(黑马线-REF(黑马线,1))/REF(黑马线,1)*100;
A3:=EMA(C,5);
A4:=((C-LLV(L,21))/(HHV(H,21)-LLV(L,21)))*100;
趋势线:(MA(3*SMA(A4,6,1)-2*SMA(SMA(A4,5,1),5,1),2)),LINETHICK2,COLORYELLOW;
A5:=(HHV(H,60)-C)/(HHV(H,60)-LLV(L,60))*100;
DRAWTEXT(FILTER(REF(黑马线,1)>90 AND A2<0,7),黑马线,'跑'),COLOR00FF00;
DRAWTEXT(CROSS(A1,黑马线)AND 黑马线<A5,黑马线,'黑马');
DRAWTEXT(CROSS(黑马线,A5)AND 趋势线<80,黑马线,'追涨');
DRAWTEXT(CROSS(趋势线,0)AND 黑马线<40,5,'大黑马');
底部:(A2<-10 AND A2>REF(A2,1))*25,COLORRED;
DRAWICON(底部 AND A3>REF(A3,1),25,4);
机会来临:REF(IF((MA(C,5)-C)/C>0.04 AND (MA(C,10)-MA(C,5))/MA(C,5)>0.04,30,0),1),COLORF00FF0;
大势已去:IF(CROSS(黑马线,A1)AND 黑马线>70 AND 趋势线>80,90,100),COLORFF0000;
短线波段王+发财树
这两个指标适合短期没有时间看盘得人。做周内波段。
MA5:MA(CLOSE,5),COLORFFFFFF,LINETHICK2;
MA13:MA(CLOSE,13),COLOR00FF00;
MA21:MA(CLOSE,21),COLOR00FFFF,LINETHICK2;
MA34:MA(CLOSE,34),COLORFF00FF;
{MA55:MA(CLOSE,55),COLOR0000FF;}
{MA120:=MA(CLOSE,120),COLORFFFF00;}
天使:=EMA(C,2),COLOR000000;
魔鬼:=EMA(SLOPE(C,21)*20+C,42),COLOR000000;
买:=CROSS(天使,魔鬼);
卖:=CROSS(魔鬼,天使);
DRAWICON(买,L*0.97,1);
DRAWTEXT(买,L*0.92,'进攻'),COLORYELLOW;
DRAWICON(卖,H*1.03,2);
DRAWTEXT(卖,H*1.08,'撤退'),COLORWHITE;
STICKLINE(天使>=魔鬼,LOW,HIGH,0.01,0),COLOR0000DD;
STICKLINE(天使>=魔鬼,CLOSE,OPEN,2,1),COLORRED;
{STICKLINE(天使>=魔鬼,CLOSE,OPEN,3,0),COLOR0000CC;
STICKLINE(天使>=魔鬼,CLOSE,OPEN,2,0),COLOR0000DD;
STICKLINE(天使>=魔鬼,CLOSE,OPEN,1,0),COLOR0000FF;}
{STICKLINE(天使<魔鬼,CLOSE,OPEN,1,0),COLOREEEE00;
STICKLINE(天使<魔鬼,CLOSE,OPEN,2,0),COLORDDDD00;
STICKLINE(天使<魔鬼,CLOSE,OPEN,3,0),COLORCCCC00;}
STICKLINE(天使<魔鬼,LOW,HIGH,0.01,0),COLORFFDD00;
STICKLINE(天使<魔鬼,CLOSE,OPEN,2,0),COLORFFFF00;
STICKLINE(CROSS(天使,魔鬼),OPEN,CLOSE,2.5,0),COLORYELLOW;
STICKLINE(CROSS(魔鬼,天使),OPEN,CLOSE,2.5,0),COLORWHITE;
发财树
趋势:SMA(((CLOSE-LLV(LOW,28))/(HHV(HIGH,28)-LLV(LOW,28))*100),3,1),COLORYELLOW;
DRAWBAND(趋势,RGB(155,50,50),50,RGB(0,100,50));
转强:IF(趋势>50,趋势,DRAWNULL),COLORRED;
转弱:IF(趋势<50,趋势,DRAWNULL),COLORGREEN;
RSV:=(CLOSE-LLV(CLOSE,9))/(HHV(CLOSE,9)-LLV(CLOSE,9))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
TYP:=(HIGH+LOW+CLOSE)/3;
CCI:=(TYP-MA(TYP,14))/(0.015*AVEDEV(TYP,14));
DIFF:=EMA(CLOSE,2)-EMA(CLOSE,55);
DEA:=EMA(DIFF,6);
MACD:=2*(DIFF-DEA);
转点:=IF(K>D AND CCI>0 AND DIFF>DEA AND MACD>0,1,0);
STICKLINE(转点=1,50,50,2,0),COLORYELLOW;
STICKLINE(转点=0,50,50,2,0),COLORCYAN;
STICKLINE(C,90,90,1,0),COLORYELLOW;
STICKLINE(C,10,10,1,0),COLORCYAN;
判断:SMA(趋势,3,1),COLORYELLOW;
IF(判断>50 AND 趋势>判断,判断,DRAWNULL ),COLORYELLOW,LINETHICK2;
IF(判断<50 AND 趋势>判断,判断,DRAWNULL),COLORFF00FF;
IF(判断>50 AND 趋势<判断,判断,DRAWNULL),COLORGREEN,LINETHICK2;
风险区:80,COLORFF85FF;
安全区:20,COLORYELLOW,POINTDOT;
顶部:90,COLORFFFF00;
强弱线:50,COLORGREEN,POINTDOT;
DRAWICON(CROSS(趋势,判断) AND 趋势<80 ,判断,1);
DRAWICON(CROSS(趋势,顶部),顶部,2);
LC:= REF(CLOSE,1);
RSI:=SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100;
VAR1:=(HHV(HIGH,9)-CLOSE)/(HHV(HIGH,9)-LLV(LOW,9))*100-70;
VAR2:=SMA(VAR1,9,1)+100;
VAR3:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
VAR4:=SMA(VAR3,3,1);
VAR5:=SMA(VAR4,3,1)+100;
VAR6:=VAR5-VAR2;
趋势1: IF(VAR6>45,VAR6-45,0),COLOR00FFFF;
VAR2Q:=REF(LOW,1);
VAR3Q:=SMA(ABS(LOW-VAR2Q),3,1)/SMA(MAX(LOW-VAR2Q,0),3,1)*100;
VAR4Q:=EMA(IF(CLOSE*1.3,VAR3Q*10,VAR3Q/10),3);
VAR5Q:=LLV(LOW,30);
VAR6Q:=HHV(VAR4Q,30);
VAR7Q:=IF(MA(CLOSE,58),1,0);
VAR8Q:=EMA(IF(LOW<=VAR5Q,(VAR4Q+VAR6Q*2)/2,0),3)/999*VAR7Q;
火焰山:=IF(VAR8Q>100,100,VAR8Q);
STICKLINE(火焰山>0,0 ,火焰山*1.2,3,0 ),COLOR4444FF;
STICKLINE(火焰山>0,0 ,火焰山*1.2,2,0 ),COLOR7777FF;
STICKLINE(火焰山>0,0 ,火焰山*1.2,1,0 ),COLOR9999FF;
STICKLINE(REF(趋势1,1)< 趋势1, 趋势1,REF(趋势1,1),3,0),COLOR000033;
STICKLINE(REF(趋势1,1)< 趋势1, 趋势1,REF(趋势1,1),2,0),COLOR000077;
STICKLINE(REF(趋势1,1)< 趋势1, 趋势1,REF(趋势1,1),1.5,0),COLOR0000BB;
STICKLINE(REF(趋势1,1)< 趋势1, 趋势1,REF(趋势1,1),1,0),COLOR0000DD;
STICKLINE(REF(趋势1,1)> 趋势1, 趋势1,REF(趋势1,1),3,0),COLOR003300;
STICKLINE(REF(趋势1,1)> 趋势1, 趋势1,REF(趋势1,1),2,0),COLOR007700;
STICKLINE(REF(趋势1,1)> 趋势1, 趋势1,REF(趋势1,1),1,0),COLOR00DD00;
逃顶:=CROSS(82,RSI);
STICKLINE( 逃顶,逃顶,20,3,0),COLORFF5500;
STICKLINE( 逃顶,逃顶,30,2,0),COLORFF8800;
STICKLINE( 逃顶,逃顶,30,1,0),COLORFFAA00;
STICKLINE( 逃顶,逃顶,30,0.5,0),COLORFFCC00;
D1:=(C+L+H)/3;
D2:=EMA(D1,6);
D3:=EMA(D2,5);
BBUY:=CROSS(D2,D3);
DRAWICON(BBUY,10,1);
VARR1:=SMA(MAX(CLOSE-REF(C,1),0),6,1)/SMA(ABS(CLOSE-REF(C,1)),6,1)*100;
DRAWICON(CROSS(82,VARR1),10,2);
DRAWTEXT(CROSS(82,VARR1),35,'减'),COLORYELLOW;
神奇线选股:(CROSS(趋势,判断) AND 趋势<80),LINETHICK0;
波段选股:(BBUY),LINETHICK0;