解盘主图源码:
TYX3:=MA(REF(HHV((C+L+O+H)/4,30),1),3);
TYX4:=MA((C+L+O+H)/4,13);
TYX5:=EMA((C+L+O+H)/4,21);
{空心红}
STICKLINE(C<TYX5 AND C>O,H,L,0,0),COLORRED;
STICKLINE(C<TYX5 AND C>O,C,O,3,1),COLORRED;
{深绿}
STICKLINE(C<TYX5 AND C<O,H,L,0,0),COLOR007700;
STICKLINE(C<TYX5 AND C<O,C,O,3,0),COLOR005500;
STICKLINE(C<TYX5 AND C<O,C,O,2,0),COLOR006600;
STICKLINE(C<TYX5 AND C<O,C,O,1,0),COLOR007700;
{蓝}
STICKLINE(C>TYX5 AND C<O,H,L,0,0),COLORFFDD44;
STICKLINE(C>TYX5 AND C<O,C,O,3,0 ),COLORFF7700;
STICKLINE(C>TYX5 AND C<O,C,O,2,0 ),COLORFFAA22;
STICKLINE(C>TYX5 AND C<O,C,O,1 ,0 ),COLORFFDD44;
{黄}
STICKLINE(C>TYX5 AND C>O,H,L,0,0 ),COLOR00EEFF;
STICKLINE(C>TYX5 AND C>O,C,O,3,0 ),COLOR00AAFF;
STICKLINE(C>TYX5 AND C>O,C,O,2,0 ),COLOR00CCFF;
STICKLINE(C>TYX5 AND C>O,C,O,1,0 ),COLOR00EEFF;
{粉红}
STICKLINE(C>TYX4 AND C>O,H,L,0,0),COLORFF66AA;
STICKLINE(C>TYX4 AND C>O,C,O,3,0 ),COLORFF11FF;
STICKLINE(C>TYX4 AND C>O,C,O,2,0 ),COLORFF44FF;
STICKLINE(C>TYX4 AND C>O,C,O,1,0 ),COLORFF66FF;
{亮灰}
STICKLINE(C>TYX4 AND C<O,H,L,0,0),COLOR999999;
STICKLINE(C>TYX4 AND C<O,C,O,3,0),COLOR555555;
STICKLINE(C>TYX4 AND C<O,C,O,2,0),COLOR777777;
STICKLINE(C>TYX4 AND C<O,C,O,1,0),COLOR999999;
{深红}
STICKLINE(C>TYX3 AND C>O,H,L,0,0),COLOR0000DD;
STICKLINE(C>TYX3 AND C>O,C,O,3,0),COLOR000099;
STICKLINE(C>TYX3 AND C>O,C,O,2,0),COLOR0000BB;
STICKLINE(C>TYX3 AND C>O,C,O,1,0),COLOR0000DD;
{涨跌停K线}
STICKLINE(HIGH=LOW AND CLOSE=OPEN AND (CLOSE/REF(CLOSE,1))>1.048,HIGH,LOW,3,0) ,COLORRED;
STICKLINE(HIGH=LOW AND CLOSE=OPEN AND (REF(CLOSE,1)/CLOSE)>1.048,HIGH,LOW,3,0) ,COLOR00FF00;
{突破}
STICKLINE(REF(COUNT(C<TYX3,5)=5,1) AND C>TYX3 AND C>O,C,O,1,0),COLOR00CCFF;
海面:MA(C,60),COLORFFFFFF,NODRAW;
乘风:MA(C,8),COLORYELLOW,LINETHICK1,NODRAW;
破浪:EMA(C,21),LINETHICK2,COLORMAGENTA;
IF(破浪>海面,海面,DRAWNULL),COLORFFFFFF;
IF(乘风>=破浪,乘风,DRAWNULL),COLORYELLOW,LINETHICK1;
IF(乘风>破浪 AND 乘风<=REF(乘风,1),乘风,DRAWNULL),COLORCYAN,LINETHICK1;
IF(破浪<=REF(破浪,1),破浪,DRAWNULL),COLORGREEN,LINETHICK2;
AA:=COUNT(CROSS(EMA(C,21),MA(C,8)),30)=1;
BB:=COUNT(CROSS(EMA(C,21),MA(C,60)),30)=1;
CC:=REF(BARSLAST(AA AND BB),1);
DD:=CC AND CROSS(MA(C,8),EMA(C,21));
DRAWTEXT(DD,(LOW * 0.99),'←乘风'),COLOR80FFFF;
2 【通达信】智慧解盘主图
A001:=CLOSE-REF(CLOSE,6);
A002:=MA(A001,6);
A003:=((CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9)))*100;
A004:=SMA(A003,3,1);
A005:=SMA(A004,3,1);
A006:=EMA((3*A004-2*A005),2);
A007:=(HIGH+LOW+CLOSE)/3;
A008:=((A007-MA(A007,14))/(0.015*AVEDEV(A007,14)))/2;
A009:=(A008+(EMA(((0-(100*(HHV(HIGH,14)-CLOSE)/(HHV(HIGH,14)-LLV(LOW,14))))+100)/100,3)*200-100))/2;
A010:=A009-REF(A009,14);
A011:=A009-REF(A009,26);
A012:=(A009+A010+A011)/3;
KKM:=EMA(A012,4);
A013:=HHV(HIGH,34);
A014:=(2*CLOSE+HIGH+LOW)/4;
A015:=LLV(LOW,34);
A016:=EMA(((A014-A015)/(A013-A015))*100,13);
A017:=EMA(0.667*REF(A016,1)+0.333*A016,2);
KKMD:=A016-A017>1 AND A016<30 AND A017<30;
KKML:=A016-A017<0 AND A016>80 AND A017>80 AND REF(A016-A017,1)>0;
KKMQ:=COUNT(A016-A017>0,2)=2;
KKAL:=(A016-A017)<0;
生命线:MA(CLOSE,20),COLOR0000FF;
取舍线:MA(CLOSE,10);
DRAWTEXT(FILTER(KKMD,30),L*1.05,'最佳买入时机'),COLOR00FFFF;
DRAWTEXT(FILTER(KKML,30),H*1.05,'最佳卖出时机'),COLORFFFF00;
DRAWTEXT(FILTER(KKMQ,30),C*1.05,'持仓区'),COLOR00FF00;
DRAWTEXT(FILTER(KKAL,30),H,'空仓区'),COLORFF8080;
DRAWTEXT(FILTER(CLOSE/REF(CLOSE,1)>INDEXC/REF(INDEXC,1),30),L*0.95,'该股强于大盘'),COLORFF00FF;
DRAWTEXT(CROSS(MA(CLOSE,5),MA(CLOSE,10)),L*0.92,'可出手'),COLORFF00FF;
DRAWTEXT(CROSS(MA(CLOSE,10),MA(CLOSE,5)),H*1.08,'收手了'),COLORFF0000;
DRAWTEXT(FILTER(KKM>EMA(KKM,4) AND KKM>REF(KKM,1),30),L*0.98,'快速介入');
DRAWTEXT(FILTER(KKM<EMA(KKM,4) AND KKM<REF(KKM,1),30),H*1.02,'风险较大');
DRAWTEXT(FILTER(KKM>EMA(KKM,4) AND KKM<REF(KKM,1),30),H,'休息观望~'),COLORAA8800;
DRAWTEXT(FILTER(KKM<EMA(KKM,4) AND KKM>REF(KKM,1),30),L,'有防御能力')
,COLORAA00AA;
3 【通达信指标公式】红蓝柱操盘指标公式-2010最新版
拉升力:=(CLOSE-LLV(LOW,28))/(HHV(HIGH,30)-LLV(LOW,36))*0.6*CLOSE;
拉升力A:=SMA(拉升力,6.3,1);
波峰波谷:SMA(拉升力A,3,1),COLORFF00FF;
拉升力B:=3*拉升力A-2.1*波峰波谷;
空方:=3*波峰波谷-1* 拉升力A;
做空:IF(空方>拉升力B,拉升力B,空方),LINETHICK2,COLOR00FF00;
做空周期:HHV(做空,21),COLORBLUE,LINETHICK2;
多头:IF(做空>=REF(做空,1) ,做空,DRAWNULL),COLORRED,LINETHICK3;
DRAWICON(做空>=REF(做空,1) AND REF(做空,1)<REF(做空,2),做空,23);
空头:IF(做空<REF(做空,1),做空,DRAWNULL),COLORGREEN,LINETHICK3;
{DRAWICON(做空<=REF(做空,1) AND REF(做空,1)>REF(做空,2),做空,19);}
短线:(CLOSE-MA(CLOSE,13))/MA(CLOSE,13)*20,LINETHICK0,COLORWHITE;
中线:(CLOSE-MA(CLOSE,4))/MA(CLOSE,4)*20,LINETHICK0,COLORYELLOW;
红柱:SMA(短线,3,1),LINETHICK0,COLOR0000FF;
蓝柱:SMA(中线,3,1),COLORSTICK,COLORFFFF00;
{红柱}
STICKLINE(红柱<REF(红柱,1)AND 红柱>0,0,红柱,2,0),COLOR888800;
STICKLINE(红柱<REF(红柱,1)AND 红柱>0,0,红柱,1.5,0),COLORAAAA00;
STICKLINE(红柱<REF(红柱,1)AND 红柱>0,0,红柱,0.8,0),COLORDDDD00;
STICKLINE(红柱<REF(红柱,1)AND 红柱>0,0,红柱,0.3,0),COLORFFFF00;
STICKLINE(红柱>REF(红柱,1)AND 红柱>0,0,红柱,2,0),COLOR000088;
STICKLINE(红柱>REF(红柱,1)AND 红柱>0,0,红柱,1.5,0),COLOR0000AA;
STICKLINE(红柱>REF(红柱,1)AND 红柱>0,0,红柱,0.8,0),COLOR0000DD;
STICKLINE(红柱>REF(红柱,1)AND 红柱>0,0,红柱,0.3,0),COLOR0000FF;
STICKLINE(蓝柱<REF(蓝柱,1) AND 蓝柱>0,0,蓝柱,2,0),COLOR008800;
STICKLINE(蓝柱<REF(蓝柱,1) AND 蓝柱>0,0,蓝柱,1,0),COLOR00AA00;
STICKLINE(蓝柱<REF(蓝柱,1) AND 蓝柱>0,0,蓝柱,0.8,0),COLOR00DD00;
STICKLINE(蓝柱<REF(蓝柱,1) AND 蓝柱>0,0,蓝柱,0.3,0),COLOR00FF00;
{蓝柱}
STICKLINE(红柱>REF(红柱,1)AND 红柱<0,0,红柱,2,0),COLOR880088;
STICKLINE(红柱>REF(红柱,1)AND 红柱<0,0,红柱,1.5,0),COLORAA00AA;
STICKLINE(红柱>REF(红柱,1)AND 红柱<0,0,红柱,0.8,0),COLORDD00DD;
STICKLINE(红柱>REF(红柱,1)AND 红柱<0,0,红柱,0.3,0),COLORFF00FF;
STICKLINE(红柱<REF(红柱,1)AND 红柱<0,0,红柱,2,0),COLOR888800;
STICKLINE(红柱<REF(红柱,1)AND 红柱<0,0,红柱,1.5,0),COLORAAAA00;
STICKLINE(红柱<REF(红柱,1)AND 红柱<0,0,红柱,0.8,0),COLORDDDD00;
STICKLINE(红柱<REF(红柱,1)AND 红柱<0,0,红柱,0.3,0),COLORFFFF00;
STICKLINE(蓝柱>REF(蓝柱,1)AND 蓝柱<0,0,蓝柱,2,0),COLOR009999;
STICKLINE(蓝柱>REF(蓝柱,1)AND 蓝柱<0,0,蓝柱,1.5,0),COLOR00BBBB;
STICKLINE(蓝柱>REF(蓝柱,1)AND 蓝柱<0,0,蓝柱,0.8,0),COLOR00DDDD;
STICKLINE(蓝柱>REF(蓝柱,1)AND 蓝柱<0,0,蓝柱,0.3,0),COLOR00FFFF;
VAR200:=(CLOSE-LLV(LOW,20))/(HHV(HIGH,20)-LLV(LOW,20))*100;
VAR300:=SMA(SMA(VAR200,3,1),3,1)/28.57;
VAR400:=EMA(VAR300,5);
操盘:=3*VAR300-2*VAR400;
A1:=CROSS(操盘,VAR300) AND VAR300<2.1 AND C>O;
STICKLINE(A1,5,0,4,0),COLOR770077;
STICKLINE(A1,5,0,3,0),COLOR990099;
STICKLINE(A1,5,0,2,0),COLORBB00BB;
STICKLINE(A1,5,0,1,0),COLORDD00DD;
STICKLINE(A1,5,0,0.3,0),COLORFF00FF;
DRAWTEXT(A1,5.2,'全仓'),COLORRED;
5 跟庄做黑马
个股:EMA(100*(C-LLV(LOW,34))/(HHV(H,34)-LLV(LOW,34)),3),COLOR1010FF;
大盘:EMA(100*(INDEXC-LLV(INDEXL,34))/(HHV(INDEXH,34)-LLV(INDEXL,34)),3),COLORE67010,LINETHICK2;
STICKLINE(个股>=大盘,个股,大盘,1,0),COLORRED;
STICKLINE(个股<大盘,个股,大盘,1,0),COLORBLUE;
STICKLINE(个股>=大盘,0,大盘,6,0),COLORYELLOW;
STICKLINE(个股<大盘,0,个股,6,0),COLORYELLOW;
短线反弹:IF(CROSS(个股,9),50,0),STICK,LINETHICK3,COLOR00FF00;
DRAWTEXT(CROSS(个股,9),40,'短线反弹!'),COLOR00FF00;
VAR1:=EMA(CLOSE,3);
VAR2:=EMA(CLOSE,21);
VAR3:=BARSLAST(CROSS(VAR2,VAR1))>15;
VAR4:=VOL>MA(VOL,5)*2 AND VOL<MA(VOL,5)*5;
VAR5:=CROSS(VAR1,VAR2) AND VAR4 AND VAR3;
黑马:IF(VAR5,80,0),STICK,LINETHICK4,COLORF00FF0;
DRAWTEXT(VAR5,70,'黑马!'),COLORF00FF0;'';
6、肖老师的<跟庄卖出指标 副图>带(资金进)的符号
VAR1:=(H+L+O+C*2)/5;
VAR2:=EMA(VAR1,21);
VAR3:=STD(VAR1,23);
VAR4:=EMA(VAR1,2);
VARA:=(VAR1-VAR2)*100/VAR3;
A:=(EMA(VARA,23)+100)/2-3,COLORBLACK;
B:=SMA(A,5,1),COLORBLACK;
大资金:4*A-3*B,COLORFF00FF,LINETHICK2;
DRAWICON(FILTER(大资金<=REF(大资金,1) AND 大资金>80,8), 大资金*1.2,6);
V1:=(C*2+H+L)/4*10;
V2:=EMA(V1,13)-EMA(V1,34);
V3:=EMA(V2,5);
V4:=2*(V2-V3)*5.5;
V5:=(HHV(INDEXH,8)-INDEXC)/(HHV(INDEXH,8)-LLV(INDEXL,8))*8;
V6:=EMA(3*V5-2*SMA(V5,18,1),5);
V7:=(INDEXC-LLV(INDEXL,8))/(HHV(INDEXH,8)-LLV(INDEXL,8))*10;
V8:=(INDEXC*2+INDEXH+INDEXL)/4;
V9:=EMA(V8,13)-EMA(V8,34);
VA:=EMA(V9,3); VB:=(V9-VA)/2;
V11:=3*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1)-2*SMA(SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1),3,1);
庄撤:IF(V4<=0,V4,0),LINETHICK3,COLORGREEN;
庄进:IF(V4>=0,V4,0),LINETHICK3,COLORRED;
资金进:IF(VB>=0,VB,0),COLORYELLOW;
资金撤:IF(VB<=0,VB,0),COLORBLUE;
买进1:(REF(大资金,1)<=0 AND 大资金>0)*100,LINETHICK2,COLORYELLOW;
买进2:(REF(资金进,1)<=0 AND 资金进>0 AND 大资金<60 and ref(大资金,1)>-30)*50,LINETHICK2,COLORblue;
7、GZX工作线主图
BBI:(MA(C,3)+MA(C,6)+MA(C,12)+MA(C,24))/4,COLORWHITE;
工作线:MA(C,14),LINETHICK2;
MA20:MA(C,20);
MA56:MA(C,56);
X6:=REF(CLOSE,1);
X7:=SMA(MAX(CLOSE-X6,0),7,1)/SMA(ABS(CLOSE-X6),7,1)*100;
X8:=CROSS(79,X7);
X9:=FILTER(X8,4);
DRAWTEXT(X9,HIGH*1.05,'←出货'),COLOR9000F5;
A3:=EMA((((SLOPE(C,21)) * 20) + C),68);
A4:=EMA(C,10);
A23:=((C + L) + H) / 3;
A24:=EMA(A23,6);
A25:=EMA(A24,5);
A26:=CROSS(A24,A25);
DRAWICON(A26,(LOW / 1.03),7),LINETHICK2,COLORMAGENTA;
VAR7:=EMA(AMOUNT/VOL/100,3);
VAR8:=EMA(VAR7,88);
VAR9:=EMA(VAR7,88)*0.85;
VARA:=VAR9*0.87;
VARB:=LOW<VARA AND CLOSE>REF(CLOSE,1)*1.02;
DRAWTEXT(FILTER(VARB,6),LOW+0.1,'坚决买进');
9、HMHN黑马黄牛
MA1:=(C+O+H+L)/4;
MA8:=MA(MA1,8);
ZQSJ:=BARSLAST(CROSS(MA1,MA8))+1;
ZRSJ:=BARSLAST(CROSS(MA8,MA1))+1;
短线:IF(ZQSJ<=ZRSJ,REF(ZRSJ,1),0),COLOR0000FF,LINETHICK2;
黑马:IF(ZQSJ<=ZRSJ,0-REF(ZRSJ,1),0),COLOR0000FF,LINETHICK2;
XXSJ:=BARSLAST(CROSS(0.8,短线))+1;
休息:IF(短线=0,XXSJ,0),COLOR00FF00,POINTDOT,LINETHICK1;
RSV:=(CLOSE-LLV(LOW,34))/(HHV(HIGH,34)-LLV(LOW,34))*100;
K:=SMA(RSV,5,1);
D:=SMA(K,5,1);
J:=3*K-2*D;
中线:IF(J>K,J,0),COLOR00FFFF,LINETHICK2;
黄牛:IF(J>K,0-J,0),COLOR00FFFF,LINETHICK2;
强势:IF(J>K AND J>=50,50,IF(J>K,J,0)),COLORFF00FF,POINTDOT,LINETHICK0;
DXDD:=L=LLV(L,3) OR C=LLV(C,3);
回头:IF(DXDD AND COUNT(短线>0 AND 中线>=30,3)>=1,-30,0),COLORFFFFFF,LINETHICK2;
LC := REF(CLOSE,1);
RSI:=SMA(MAX(CLOSE-LC,0),2,1)/SMA(ABS(CLOSE-LC),2,1)*200-100;
RSI6:=SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*200-100;
MA2:=MA(RSI,2);
太阳:IF(MA2>90 AND RSI6>50,1,0),COLOR0000FF,POINTDOT,LINETHICK0;
STICKLINE(中线>50 AND 中线>=REF(中线,1),50,中线,8,0),COLOR0000FF;
STICKLINE(中线>50 AND 中线<=REF(中线,1),50,中线,8,0),COLOR00FF00;
STICKLINE(中线>100,100,中线,8,0),COLORFFFFFF;
DRAWICON(太阳,中线*1.3,3);
10、黑马追涨
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,COLORRED;
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,COLORBLUE;
IF(趋势线>REF(趋势线,1),趋势线,趋势线+2*(趋势线-REF(趋势线,1))),LINETHICK2,COLORYELLOW;
A5:=(HHV(H,60)-C)/(HHV(H,60)-LLV(L,60))*100;
A6:=REF(趋势线,2);
DRAWTEXT(FILTER(REF(黑马线,1)>90 AND A2<0,7),黑马线,'跑'),COLORBLUE;
DRAWTEXT(CROSS(A1,黑马线)AND 黑马线<A5,黑马线,'黑马');
DRAWTEXT(CROSS(黑马线,A5)AND 趋势线<80,黑马线,'追涨');
DRAWTEXT(CROSS(趋势线,0)AND 黑马线<40,5,'大黑马');
DRAWTEXT(趋势线<REF(趋势线,1) AND A6<REF(趋势线,1),80,'卖'),COLORBLUE;
DRAWTEXT(趋势线>REF(趋势线,1) AND A6>REF(趋势线,1),30,'买'),COLORYELLOW;
底部: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),COLORMAGENTA;
大势已去:IF(CROSS(黑马线,A1)AND 黑马线>70 AND 趋势线>80,90,100),COLORBLUE;
11、HNJX黑牛均线
买线:=EMA(C,2);
卖线:=EMA(SLOPE(C,21)*20+C,42);
BU:=CROSS(买线,卖线);
SEL:=CROSS(卖线,买线);
DRAWICON(BU,L-0.1,1);
DRAWICON(SEL,H+0.1,2);
STICKLINE(买线>=卖线,LOW,HIGH,0.0,1),COLORRED;
STICKLINE(买线>=卖线,CLOSE,OPEN,2,1),COLORRED;
STICKLINE(买线<卖线,LOW,HIGH,0.0,1),COLORGREEN;
STICKLINE(买线<卖线,CLOSE,OPEN,2,1),COLORGREEN;
STICKLINE(BU,OPEN,CLOSE,2,0),COLORYELLOW;
STICKLINE(SEL,OPEN,CLOSE,2,0),COLORBLUE;
主力:EMA(CLOSE,10),COLORRED;
散户:EMA(CLOSE,5),COLORWHITE;
绿降:(46.18*EMA(CLOSE,10)-31.82*EMA(CLOSE,4))/14.36,COLORGREEN,LINETHICK1;
操盘:MA(CLOSE,9),COLORCYAN,LINETHICK2;
界点:MA(CLOSE,20),COLORMAGENTA;
12、极品波段
DIFF:=EMA(C,5)-EMA(C,20);DEA:=EMA(DIFF,10);
MACD:600*(DIFF-DEA)/EMA(C,30), COLORRED ,POINTDOT;
RSV:=(C-LLV(L,20))/(HHV(H,20)-LLV(L,20))*100;
FK:=SMA(RSV,5,1);
K20:SMA(FK,3,1), POINTDOT, COLORYELLOW;
D20:SMA(K20,3,1), POINTDOT, COLORFF9999;
STICKLINE(K20>=D20,D20,K20,3,0),COLORFF00FF;
STICKLINE(K20<=D20,D20,K20,3,0),COLORFFFF00;
V1:=LLV(LOW,10);
V2:=HHV(H,25);
价位线:=EMA((C-V1)/(V2-V1)*4,4);
买入:STICKLINE(CROSS(价位线,0.3),50,5,2,0), COLOR00CCFF,LINETHICK1;
STICKLINE(CROSS(价位线,0.3),30,5,2,0),COLORRED,LINETHICK1;
卖出:STICKLINE(CROSS(3.5,价位线),60,100,2,0), COLORRED,LINETHICK2;
STICKLINE(CROSS(3.5,价位线),80,100,2,0), COLORFF9900,LINETHICK2;
DRAWTEXT(CROSS(价位线,0.3),55,'买'),COLORF00FF0;
DRAWTEXT(CROSS(3.5,价位线),55,'卖'),COLOR00FF00;
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)/618*VAR7Q;
VAR9Q:=IF(VAR8Q>100,100,VAR8Q);
吸筹:STICKLINE(VAR9Q>-120,0,VAR9Q,6,1),COLORYELLOW;
AA3:=(HHV(HIGH,21)-CLOSE)/(HHV(HIGH,21)-LLV(LOW,21))*100-10;
AA4:=(CLOSE-LLV(LOW,21))/(HHV(HIGH,21)-LLV(LOW,21))*100;
AA5:=SMA(AA4,13,8);
走势:=CEILING(SMA(AA5,13,8));
AA6:=SMA(AA3,21,8);
卖临界: STICKLINE(走势-AA6>85,98,90,15,1),COLORFFFF00;
13、大盘主力进出
{红色线表示主力
黄色线表示多方
蓝色线表示空方
至于如何应用 自己对着大盘K线收拉缩放去理解就行了 (通达信也能用)}
{大盘主力进出}
{p1: 1.100.10; p2: 1.100.10; p3: 1.100.20}
Var1:=1;
Var2:=INDEXA/100000000;{大盘成交额}
Var3:=INDEXADV;{大盘上涨家数}
Var4:=INDEXDEC;{大盘下跌家数}
Var5:=Var3/(Var3+Var4)*Var2;
Var6:=Var4/(Var3+Var4)*Var2;
Var7:=EMA(Var5,P1);
Var8:=EMA(Var6,P1);
Var9:=EMA(Var7,P2);
VarA:=EMA(Var8,P3);
lh: EMA(Var7,3)*Var1,COLORRED;
{lh2: EMA(Var7,1)*Var1;}
ml1: EMA(Var9,5)*Var1;
ml2: EMA(VarA,1)*Var1,colorE50000;
ml:ml1 -ml2*Var1, VOLSTICK;
14、大盘动向及资金流向
MAV:=INDEXA/1000000;
VAR1:=(INDEXC*2+INDEXH+INDEXL)/4;
VAR2:=(INDEXC*2+INDEXH+INDEXL)/4;
VAR3:=EMA(VAR2,13)-EMA(VAR2,34);
VARA:=EMA(VAR3,5);
VARB:=(VAR3-VARA)/2*1000;
大盘资金:VARB,COLORYELLOW,LINETHICK1;
VARC:=EMA(VAR1,13)-EMA(VAR1,34);
VARD:=EMA(VARC,5);
多方能量: 2*(VARC-VARD)*3.8*100,COLORRED;
空方能量: (-2)*(VARC-VARD)*3.8*100,COLORGREEN;
强弱分界:0,COLORCYAN,CIRCLEDOT;
公式源码如下:
换手:VOL/CAPITAL*100,NODRAW;
STICKLINE(C,0,换手,2,0),COLOR408080;
{累计:SUM(换手,3),LINESTICK;}
STICKLINE(换手>5,5,换手,2,0),COLORRED;
STICKLINE(换手>17,17,换手,2,0),COLORGREEN;
换手率过5反红:0,NODRAW,COLOR00FFFF;
低位绿庄家进货:0,NODRAW,COLOR0000FF;
高位绿庄家出货:0,NODRAW,COLOR00FF80;
启动线:MA(换手,M1);
洗盘线:MA(换手,M2);
异动线:MA(换手,M3);
M1参数:2 1000 5
M2参数:2 1000 35
M3参数:2 1000 135
飞狐的源码是:
{成交量趋势拐点与换手率
参数:M1参数:2 1000 5
M2参数:2 1000 35
M3参数:2 1000 135}
M1:=5;
M2:=35;
M3:=135;
换手:VOL/CAPITAL*100;
STICKLINE(C,0,换手,8,0),COLOR408080;
{累计:SUM(换手,3),LINESTICK;}
STICKLINE(换手>5,5,换手,8,0),COLORRED;
STICKLINE(换手>17,17,换手,8,0),COLORGREEN;
换手率过5反红:0,COLOR00FFFF;
低位绿庄家进货:0,COLOR0000FF;
高位绿庄家出货:0,COLOR00FF80;启动线:MA(换手,M1);
洗盘线:MA(换手,M2);
异动线:MA(换手,M3);
16、回调均线选股(想选什么均线就选什么均线)
此公式选择的是回调均线的股票,注意如果买入后破了你选择的均线记住止损,均线随便你选择5或20 或30,具体参考大盘情况和具体股票,源码如下:
n是天数可以取20日或30日;m为均线(设的是30)
ar1:=hhv(c,n);
ar2:=abs((c-ma(c,m))/ma(c,m)*100)<=2;
回调均线:ar2 and c<ar1 and ma(c,m)>ref(ma(c,m),1) and ma(v,5)>ref(ma(v,5),1);
17、
三角突破选股代码如下:
HIGHN:=10;LOWN:=10;HIGHDISPLAY:=0;LOWDISPLAY:=0;ZGDISPLAY:=0;MADISPLAY:=0;
AA5:=REF(H,HIGHN)=HHV(H,2*HIGHN+1);
QY:=BACKSET(AA5,HIGHN+1);
CC:=FILTER(QY,HIGHN) AND H=HHV(H,HIGHN+1);
DDD:=BARSLAST(CC);
GDTS:=IF(CC,CURRBARSCOUNT,0);
DINGBU:=IF(DDD,REF(H,DDD),H);{顶部}
DINGBUTS:=IF(DDD,REF(GDTS,DDD),GDTS);
DINGBU1:=REF(DINGBU,DDD+1);
GDCS1:=CONST(DINGBUTS);
DINGBUTS1:=REF(DINGBUTS,DDD+1);
GDCS2:=CONST(DINGBUTS1);
DINGBU2:=REF(DINGBU1,DDD+1);
MM:=IF(CURRBARSCOUNT>GDCS2,0,1);
高点压力:=DRAWLINE(CURRBARSCOUNT=GDCS2,H,CURRBARSCOUNT=GDCS1,H,1) COLORGREEN,LINETHICK1;
AA1:=REF(L,LOWN)=LLV(L,2*LOWN+1);
QY1:=BACKSET(AA1,LOWN+1);
CC1:=FILTER(QY1,LOWN) AND L=LLV(L,LOWN+1);
DD1:=BARSLAST(CC1);
DDTS:=IF(CC1,CURRBARSCOUNT,0);
YDB:=IF(DD1,REF(L,DD1),L);
DDTS1:=IF(DD1,REF(DDTS,DD1),DDTS);
DDCS1:=CONST(DDTS1);
ZDB:=REF(YDB,DD1+1);
DDTS2:=REF(DDTS1,DD1+1);
DDCS2:=CONST(DDTS2);
低点支撑:=DRAWLINE(CURRBARSCOUNT=DDCS2,L,CURRBARSCOUNT=DDCS1,L,1) COLORRED,LINETHICK1;
XG:高点压力<REF(高点压力,1) AND REF(高点压力,1)<REF(高点压力,2) AND C>高点压力 AND CROSS(C,高点压力) AND (高点压力-低点支撑)/低点支撑<0.05 AND 高点压力>低点支撑 AND VOL>MA(VOL,5)*1.5;
主图代码如下:
MA5:MA(CLOSE,5),COLORWHITE;
MA10:MA(CLOSE,10),COLORYELLOW;
MA20:MA(CLOSE,20),COLORDD00DD;
MA30:MA(CLOSE,30),COLORGREEN;
MA60:MA(CLOSE,60),COLORC7C9FF;
MA120:MA(CLOSE,120),COLORRED;
MA250:MA(CLOSE,250)COLORBLUE;
HIGHN:=10;LOWN:=10;HIGHDISPLAY:=0;LOWDISPLAY:=0;ZGDISPLAY:=0;MADISPLAY:=0;
AA5:=REF(H,HIGHN)=HHV(H,2*HIGHN+1);
QY:=BACKSET(AA5,HIGHN+1);
CC:=FILTER(QY,HIGHN) AND H=HHV(H,HIGHN+1);
DDD:=BARSLAST(CC);
GDTS:=IF(CC,CURRBARSCOUNT,0);
DINGBU:=IF(DDD,REF(H,DDD),H);{顶部}
DINGBUTS:=IF(DDD,REF(GDTS,DDD),GDTS);
DINGBU1:=REF(DINGBU,DDD+1);
GDCS1:=CONST(DINGBUTS);
DINGBUTS1:=REF(DINGBUTS,DDD+1);
GDCS2:=CONST(DINGBUTS1);
DINGBU2:=REF(DINGBU1,DDD+1);
MM:=IF(CURRBARSCOUNT>GDCS2,0,1);
高点压力:DRAWLINE(CURRBARSCOUNT=GDCS2,H,CURRBARSCOUNT=GDCS1,H,1) COLORGREEN,LINETHICK1;
AA1:=REF(L,LOWN)=LLV(L,2*LOWN+1);
QY1:=BACKSET(AA1,LOWN+1);
CC1:=FILTER(QY1,LOWN) AND L=LLV(L,LOWN+1);
DD1:=BARSLAST(CC1);
DDTS:=IF(CC1,CURRBARSCOUNT,0);
YDB:=IF(DD1,REF(L,DD1),L);
DDTS1:=IF(DD1,REF(DDTS,DD1),DDTS);
DDCS1:=CONST(DDTS1);
ZDB:=REF(YDB,DD1+1);
DDTS2:=REF(DDTS1,DD1+1);
DDCS2:=CONST(DDTS2);
低点支撑:DRAWLINE(CURRBARSCOUNT=DDCS2,L,CURRBARSCOUNT=DDCS1,L,1) COLORRED,LINETHICK1;
ZGSTAR:=(高点压力+低点支撑)/2;
ZGEND:=CONST((高点压力+低点支撑)/2);
STARDAY:=IF(DDCS2<GDCS2,DDCS2,GDCS2);
中轨:DRAWLINE(CURRBARSCOUNT=STARDAY,ZGSTAR,ISLASTBAR,ZGEND,1),COLORFF55BB,LINETHICK1;
DRAWLINE(CURRBARSCOUNT=DDCS1,L,ISLASTBAR,REF(L,DDCS1-1),1),COLORMAGENTA,POINTDOT,;
DRAWLINE(CURRBARSCOUNT=DDCS2,L,ISLASTBAR,REF(L,DDCS2-1),1),COLORCYAN,POINTDOT;
DRAWLINE(CURRBARSCOUNT=GDCS2,H,ISLASTBAR,REF(H,GDCS2-1),1),COLOR0055FF,POINTDOT;
DRAWLINE(CURRBARSCOUNT=GDCS1,H,ISLASTBAR,REF(H,GDCS1-1),1),COLORYELLOW,POINTDOT;
DRAWTEXT(CROSS(-6,(CLOSE-MA(CLOSE,12))/MA(CLOSE,12)*100),(LOW * 0.96),'明均低买'),COLORRED;
MTM:=C-REF(C,1);
DX:=100*EMA(EMA(MTM,6),6)/EMA(EMA(ABS(MTM),6),6);
买:=LLV(DX,2)=LLV(DX,7) AND COUNT(DX<0,2) AND CROSS(DX,MA(DX,2));
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);
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;
DRAWICON(VAR19 AND FILTER(买=1,5),L*0.98,1);
VAR4A:=EMA(CLOSE,3);
YC_买进:=((CLOSE-REF(MA(CLOSE,6),1))/6+MA(CLOSE,6))*1.004;
买进条件:=CROSS(CLOSE,YC_买进) AND YC_买进>REF(YC_买进,1),LINETHICK0;
YC_加仓:=((CLOSE-REF(MA(CLOSE,18),1))/18+MA(CLOSE,18))*1.004;
加仓条件:=CROSS(CLOSE,YC_加仓) AND YC_加仓>REF(YC_加仓,1),LINETHICK0;
DRAWICON(COUNT(REF(VAR4A,1)<REF(VAR4A,2),5)=5 AND VAR4A>REF(VAR4A,1) AND 买进条件 AND 加仓条件,L*0.96,9);
XG:=高点压力<REF(高点压力,1) AND REF(高点压力,1)<REF(高点压力,2) AND C>高点压力 AND CROSS(C,高点压力) AND (高点压力-低点支撑)/低点支撑<0.05 AND 高点压力>低点支撑 AND VOL>MA(VOL,5)*1.5;
DRAWTEXT(XG,(LOW * 0.9),'三角整理突破'),COLORYELLOW;
VAR100:=IF(DATE<=1090831,1,0);
CSS:=((CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8))*100)*VAR100;
YJDD:=(EMA(CSS,3)-50)*2* VAR100;
强弱:=(YJDD+100)/2* VAR100;
ST:=CROSS(20,强弱);
AA:=REF(CLOSE,1);
BBB:=SMA(MAX(CLOSE-AA,0),5,1)/SMA(ABS(CLOSE-AA),5,1)*1000;
HHH:=BBB-LLV(BBB,10);
SS:=(MA(HHH,2)*3+HHH*13)/16;
短线买点:=IF(SS>13,MA(SS,2),SS)/6;
短线出击:=IF(CROSS(短线买点,1) AND (短线买点<30),30,1);
JDSJ:=BARSLAST(ST);
拼凑选:=IF(COUNT(ST<=1,JDSJ)=JDSJ AND BETWEEN(JDSJ,0,3),JDSJ,0) AND 短线出击=30,COLOR00FF00;
DRAWTEXT(拼凑选,(LOW * 0.89),'中尉拼凑'),COLORGREEN;