很牛的主图时间之窗通达信指标公式源码

合集下载

通达信指标公式源码涨停时间窗 主图 副图

通达信指标公式源码涨停时间窗 主图 副图

ZT:=C/ref(C,1)>1.097;XH:=FILTER(ZT,13);BH:=BARSLAST(ZT);CZ:=REF(H,BH)-REF(L,BH);STICKLINE(C,(REF(L,BH)+CZ*0.5),(REF(L,BH)+CZ*0.5),7,0),COLORRED; STICKLINE(C,REF(L,BH),REF(L,BH),7,0),COLORBLUE;STICKLINE(ZT,REF(O,BH),REF(C,BH),7,0),COLORYELLOW; DRAWTEXT(ZT,L*0.98,'涨停'),COLORf00ff0;varZT:=BARSLAST(C/REF(C,1)>1.097);stickline(varZT=2,l*0.97,l*0.98,8,0),color0000ff;drawtext(varZT=2,l*0.95,'3天'),coloryellow;stickline(varZT=4,h*1.03,h*1.02,8,0),color9966ff;drawtext(varZT=4,h*1.06,'5天'),coloryellow;stickline(varZT=7,l*0.97,l*0.98,8,0),color00ffff;drawtext(varZT=7,l*0.95,'8天'),coloryellow;stickline(varZT=12,h*1.03,h*1.02,8,0),colorff33ff;drawtext(varZT=12,h*1.06,'13天'),coloryellow;stickline(varZT=20,l*0.97,l*0.98,8,0),color0066ff;drawtext(varZT=20,l*0.95,'21天'),coloryellow;stickline(varZT=33,h*1.03,h*1.02,8,0),color9932CD;drawtext(varZT=33,h*1.06,'34天'),coloryellow;stickline(varZT=54,l*0.97,l*0.98,8,0),color006600;drawtext(varZT=54,l*0.95,'55天'),coloryellow;stickline(varZT=88,h*1.03,h*1.02,8,0),color00ff00;drawtext(varZT=88,h*1.06,'89天'),coloryellow;stickline(varZT=143,l*0.97,l*0.98,8,0),colorccffff;drawtext(varZT=143,l*0.95,'144天'),coloryellow;stickline(varZT=232 ,h*1.03,h*1.02,8,0),colorff0033;drawtext(varZT=232,h*1.06,'233天'),coloryellow;stickline(varZT=376,l*0.97,l*0.98,8,0),colorff9966;drawtext(varZT=376,l*0.95,'377天'),coloryellow;-------------------------------------------------------------涨停时间(窗),副图:N:=13;WR大于80考虑买:100*(HHV(HIGH,N)-CLOSE)/(HHV(HIGH,N)-LLV(LOW,N)),linethick0; 均价:amount/(vol*100),linethick0,coloryellow;ZT:=C/ref(C,1)>1.097;XH:=FILTER(ZT,13);BH:=BARSLAST(ZT);STICKLINE(ZT,0,L*0.7,4,0),COLORYELLOW;DRAWTEXT(ZT,L*0.8,'涨停'),COLORf00ff0;varZT:=BARSLAST(C/REF(C,1)>1.097);AA:=BETWEEN(C,REF(L,BH)*1.01,REF(L,BH)*0.987);stickline(AA,0,L*0.3,2,0),colorblue;drawtext(AA,L*0.4,'警戒'),colorwhite;stickline(AA and varzt=2,0,L*0.5,2,0),colorred;drawtext(AA and varzt=2,L*0.5,'时间窗'),colorwhite;stickline(AA and varzt=4,0,L*0.5,2,0),colorred;drawtext(AA and varzt=4,L*0.5,'时间窗'),colorwhite;stickline(AA and varzt=7,0,L*0.5,2,0),colorred;drawtext(AA and varzt=7,L*0.5,'时间窗'),colorwhite;stickline(AA and varzt=12,0,L*0.5,2,0),colorred;drawtext(AA and varzt=12,L*0.5,'时间窗'),colorwhite;stickline(AA and varzt=20,0,L*0.5,2,0),colorred;drawtext(AA and varzt=20,L*0.5,'时间窗'),colorwhite;。

通达信最牛分时主图公式源码

通达信最牛分时主图公式源码

通达信最牛分时主图公式源码现将我近段时间,找到的最牛分时主图分享出来攻击量:=((HSL*0.50+REF(HSL,1)*0.33)+(REF(HSL,2)*0.17))*SUM(C,FROMOPEN)/FROMOPEN;攻击量A:=SUM(IF(C>REF(C,1),攻击量*V,0),FROMOPEN),COLOR0000FF,LINETHICK0;攻击量B:=-SUM(IF(C<REF(C,1),攻击量*V,0),FROMOPEN),COLOR00FF00,LINETHICK0;攻击流量:=攻击量A+攻击量B,COLORSTICK;攻击比:=攻击流量/SUM(V,FROMOPEN)*100,COLORRED,LINETHICK1;资金攻击度:=IF(攻击比>=0,(攻击比+50),100-ABS((攻击比-50)));资金流入:=SUM(IF(C>REF(C,1),V,0),FROMOPEN),STICK,COLORRED;资金流出:=-SUM(IF(C<REF(C,1),V,0),FROMOPEN),STICK,COLOR00FF00;资金出入:=资金流入+资金流出,COLORSTICK;资金比:=资金出入/SUM(V,FROMOPEN)*100,COLOR00FFFF,LINETHICK1;资金流量比:=IF(资金比>=0,(资金比+100)/2,100-ABS((资金比-100)/2));DRAWTEXT_FIX(1,0.250,0.88,0,STRCAT(STRCAT('【资金流量比】',CON2STR(资金流量比,2)),'%买')),COLORCYAN;DRAWTEXT_FIX(1,0.000,0.88,0,STRCAT(STRCAT('【资金攻击度】',CON2STR(资金攻击度,2)),' %买')),COLORCYAN;XG:HHV(H,480),DOTLINE,COLORRED;STICKLINE(FILTER(CROSS(C,REF(XG,1)),10) AND C>REF(XG,1),C*0.99,C,8,0),COLORGREEN;DRAWTEXT(FILTER(CROSS(C,REF(XG,1)),10) AND C>REF(XG,1),C*0.99,'突破'),COLORYELLOW;RQ:=DATETODAY(DATE)-DATETODAY(REF(DATE,TOTALBARSCOUNT-CURRBARSCOUNT))+1;JY:=BARSLAST((RQ-REF(RQ,1))!=WEEKDAY-REF(WEEKDAY,1) OR TOTALBARSCOUNT-CURRBARSCOUNT=0)+1;MA1:=REF(C,JY);MA2:=REF(MA1,JY);MA3:=REF(MA2,JY);MA4:=REF(MA3,JY);MA5:=REF(MA4,JY);MA6:=REF(MA5,JY);MA7:=REF(MA6,JY);MA8:=REF(MA7,JY);MA9:=REF(MA8,JY);CK:REFDATE((C+MA1+MA2+MA3+MA4+MA5+MA6+MA7+MA8+MA9)/10,DATE),COLORAC59FF,CIRCLEDOT; DRAWTEXT(ISLASTBAR,CK,' 参考线'),COLOR0000FF;DIF:=(EMA(CLOSE,12)-EMA(CLOSE,26))+DYNAINFO(3);DEA:=EMA(DIF,9);MACD1:=10*(DIF-DEA);MACD2:=EMA(MACD1,2);STICKLINE(MACD1>=MACD2 AND MACD1>=0,DYNAINFO(3),MACD1+DYNAINFO(3),0,0),COLOR0000B4; STICKLINE(MACD1<MACD2 AND MACD1>0,DYNAINFO(3),MACD1+DYNAINFO(3),0,0),COLOR00B400; STICKLINE(MACD1>=MACD2 AND MACD1<0,DYNAINFO(3),MACD1+DYNAINFO(3),0,0),COLOR5151A2; STICKLINE(MACD1<MACD2 AND MACD1<0,DYNAINFO(3),MACD1+DYNAINFO(3),0,0),COLOR88743A;XX:=SUM(AMOUNT,BARSCOUNT(CLOSE))/SUM(V*100,BARSCOUNT(CLOSE));主力:=EXPMA(CLOSE/XX,20);大户:=EXPMA(CLOSE/XX,60);散户:=EXPMA(CLOSE/XX,120);底:=1;1.02,NODRAW;高:=1.03;DRAWTEXT(CROSS(主力,1.02),C*0.999,'-拉升'),COLORCYAN;DRAWICON(CROSS(主力,1.04),C,24);DRAWTEXT(CROSS(主力,1.04),C*0.999,'-冲涨停'),COLORLIMAGENTA;A1:=(VOL/CLOSE)/3;A2:=SUM((IF(((A1>40) AND (CLOSE>(REF(CLOSE,1)))),A1,0)),0);A3:=SUM((IF(((A1>40) AND (CLOSE<(REF(CLOSE,1)))),A1,0)),0);A4:=SUM((IF(((A1<40) AND (CLOSE>(REF(CLOSE,1)))),A1,0)),0);A5:=SUM((IF(((A1<40) AND (CLOSE<(REF(CLOSE,1)))),A1,0)),0);A6:=((A2+A3)+A4)+A5;A7:=IF((BARSTATUS=2),((100*A2)/A6),0);A8:=((IF((BARSTATUS=2),((100*A3)/A6),0)));A9:=((IF((BARSTATUS=2),((100*A4)/A6),0)));A10:=((IF((BARSTATUS=2),((100*A5)/A6),0)));机构买盘:=(A2),LINETHICK2;机构卖盘:=(A3),LINETHICK2;散户买盘:=(A4);散户卖盘:=(A5);DRAWTEXT_FIX(1,0.000,1-0.05,0,STRCAT(STRCAT('【机构买盘】',CON2STR(机构买盘,2)),'万')),COLORRED; DRAWTEXT_FIX(1,0.250,1-0.05,0,STRCAT(STRCAT('【机构卖盘】',CON2STR(机构卖盘,2)),'万')),COLOR00FF00;DRAWTEXT_FIX(1,0.500,1-0.05,0,STRCAT(STRCAT('【散户买盘】',CON2STR(散户买盘,2)),'万')),COLORRED; DRAWTEXT_FIX(1,0.745,1-0.05,0,STRCAT(STRCAT('【散户卖盘】',CON2STR(散户卖盘,2)),'万')),COLOR00FF00;H1:=MAX(DYNAINFO(3),DYNAINFO(5));L1:=MIN(DYNAINFO(3),DYNAINFO(6));P1:=H1-L1;阻力:=L1+P1*7/8,COLORGREEN;支撑:=L1+P1*0.5/8,COLORMAGENTA;DRAWTEXT(LONGCROSS(支撑,C,2),C,'买'),COLORYELLOW;DRAWTEXT(LONGCROSS(C,阻力,2),C,'卖'),COLORGREEN;量价:=(VOL/CLOSE)/3;B2:=SUM((IF(((量价>0.20) AND (CLOSE>(REF(CLOSE,1)))),量价,0)),0);B3:=SUM((IF(((量价>0.20) AND (CLOSE<(REF(CLOSE,1)))),量价,0)),0);B6:=B2+B3;DD1:=1;比:=B2/B3;{}BBB1:=STRCAT(STRCAT('买= ',CON2STR((100*B2)/B6,0)),'%');BBB2:=STRCAT(STRCAT('卖= ',CON2STR((100*B3)/B6,0)),'%');BBB3:=STRCAT(STRCAT('差= ',CON2STR((100*(B2-B3))/B6,0)),'%');DRAWTEXT_FIX(DD1=1,0,0.70,0,BBB1),COLORRED;DRAWTEXT_FIX(DD1=1,0,0.75,0,BBB2),COLORGREEN;DRAWTEXT_FIX(DD1=1,0,0.80,0,BBB3),COLOR00FFFF;攻击量赋值:((换手线*0.50+1日前的换手线*0.33)+(2日前的换手线*0.17))*收盘价的当前离开盘分钟数日累和/当前离开盘分钟数攻击量A赋值:如果收盘价>1日前的收盘价,返回攻击量*成交量(手),否则返回0的当前离开盘分钟数日累和,COLOR0000FF,线宽为0攻击量B赋值:-如果收盘价<1日前的收盘价,返回攻击量*成交量(手),否则返回0的当前离开盘分钟数日累和,COLOR00FF00,线宽为0攻击流量赋值:攻击量A+攻击量B,COLORSTICK攻击比赋值:攻击流量/成交量(手)的当前离开盘分钟数日累和*100,画红色,线宽为1资金攻击度赋值:如果攻击比>=0,返回(攻击比+50),否则返回100-(攻击比-50)的绝对值资金流入赋值:如果收盘价>1日前的收盘价,返回成交量(手),否则返回0的当前离开盘分钟数日累和,STICK,画红色资金流出赋值:-如果收盘价<1日前的收盘价,返回成交量(手),否则返回0的当前离开盘分钟数日累和,STICK,COLOR00FF00资金出入赋值:资金流入+资金流出,COLORSTICK资金比赋值:资金出入/成交量(手)的当前离开盘分钟数日累和*100,COLOR00FFFF,线宽为1资金流量比赋值:如果资金比>=0,返回(资金比+100)/2,否则返回100-(资金比-100)/2的绝对值当满足条件1时,在横轴0.250纵轴0.88位置书写文字,画青色当满足条件1时,在横轴0.000纵轴0.88位置书写文字,画青色输出XG:480日内最高价的最高值,DOTLINE,画红色当满足条件收盘价上穿1日前的XG的10日过滤ANDC>1日前的XG时,在收盘价*0.99和收盘价位置之间画柱状线,宽度为8,0不为0则画空心柱.,画绿色当满足条件收盘价上穿1日前的XG的10日过滤ANDC>1日前的XG时,在收盘价*0.99位置书写文字,画黄色RQ赋值:日期对应的转换天数-总的周期数-到最后交易的周期日前的日期对应的转换天数+1JY赋值:上次(RQ-1日前的RQ)不等于星期-1日前的星期ORTOTALBARSCOUNT-到最后交易的周期=0距今天数+1 MA1赋值:JY日前的收盘价MA2赋值:JY日前的MA1MA3赋值:JY日前的MA2MA4赋值:JY日前的MA3MA5赋值:JY日前的MA4MA6赋值:JY日前的MA5MA7赋值:JY日前的MA6MA8赋值:JY日前的MA7MA9赋值:JY日前的MA8输出CK:日期日(收盘价+MA1+MA2+MA3+MA4+MA5+MA6+MA7+MA8+MA9)/10,COLORAC59FF,CIRCLEDOT 当满足条件是否最后一个周期时,在CK位置书写文字,COLOR0000FFDIF赋值:(收盘价的12日指数移动平均-收盘价的26日指数移动平均)+前收盘价DEA赋值:DIF的9日指数移动平均MACD1赋值:10*(DIF-DEA)MACD2赋值:MACD1的2日指数移动平均当满足条件MACD1>=MACD2ANDMACD1>=0时,在前收盘价和MACD1+前收盘价位置之间画柱状线,宽度为0,0不为0则画空心柱.,COLOR0000B4当满足条件MACD1<MACD2ANDMACD1>0时,在前收盘价和MACD1+前收盘价位置之间画柱状线,宽度为0,0不为0则画空心柱.,COLOR00B400当满足条件MACD1>=MACD2ANDMACD1<0时,在前收盘价和MACD1+前收盘价位置之间画柱状线,宽度为0,0不为0则画空心柱.,COLOR5151A2当满足条件MACD1<MACD2ANDMACD1<0时,在前收盘价和MACD1+前收盘价位置之间画柱状线,宽度为0,0不为0则画空心柱.,COLOR88743AXX赋值:成交额(元)的收盘价的有效数据周期数日累和/成交量(手)*100的收盘价的有效数据周期数日累和主力赋值:收盘价/XX的20日指数移动平均大户赋值:收盘价/XX的60日指数移动平均散户赋值:收盘价/XX的120日指数移动平均底赋值:11.02,NODRAW高赋值:1.03当满足条件主力上穿1.02时,在收盘价*0.999位置书写文字,画青色当满足条件主力上穿1.04时,在收盘价位置画24号图标当满足条件主力上穿1.04时,在收盘价*0.999位置书写文字,画淡洋红色A1赋值:(成交量(手)/收盘价)/3A2赋值:(如果((A1>40)AND(收盘价>(1日前的收盘价))),返回A1,否则返回0)的历史累和A3赋值:(如果((A1>40)AND(收盘价<(1日前的收盘价))),返回A1,否则返回0)的历史累和A4赋值:(如果((A1<40)AND(收盘价>(1日前的收盘价))),返回A1,否则返回0)的历史累和A5赋值:(如果((A1<40)AND(收盘价<(1日前的收盘价))),返回A1,否则返回0)的历史累和A6赋值:((A2+A3)+A4)+A5A7赋值:如果(数据位置状态=2),返回((100*A2)/A6),否则返回0A8赋值:((如果(数据位置状态=2),返回((100*A3)/A6),否则返回0))A9赋值:((如果(数据位置状态=2),返回((100*A4)/A6),否则返回0))A10赋值:((如果(数据位置状态=2),返回((100*A5)/A6),否则返回0))机构买盘赋值:(A2),线宽为2机构卖盘赋值:(A3),线宽为2散户买盘赋值:(A4)散户卖盘赋值:(A5)当满足条件1时,在横轴0.000纵轴1-0.05位置书写文字,画红色当满足条件1时,在横轴0.250纵轴1-0.05位置书写文字,COLOR00FF00当满足条件1时,在横轴0.500纵轴1-0.05位置书写文字,画红色当满足条件1时,在横轴0.745纵轴1-0.05位置书写文字,COLOR00FF00H1赋值:前收盘价和最高的较大值L1赋值:前收盘价和最低的较小值P1赋值:H1-L1阻力赋值:L1+P1*7/8,画绿色支撑赋值:L1+P1*0.5/8,画洋红色当满足条件支撑小于收盘价保持2个交易日后交叉上穿时,在收盘价位置书写文字,画黄色当满足条件收盘价小于阻力保持2个交易日后交叉上穿时,在收盘价位置书写文字,画绿色量价赋值:(成交量(手)/收盘价)/3B2赋值:(如果((量价>0.20)AND(收盘价>(1日前的收盘价))),返回量价,否则返回0)的历史累和B3赋值:(如果((量价>0.20)AND(收盘价<(1日前的收盘价))),返回量价,否则返回0)的历史累和B6赋值:B2+B3DD1赋值:1比赋值:B2/B3BBB1赋值:字符串相加BBB2赋值:字符串相加BBB3赋值:字符串相加当满足条件DD1=1时,在横轴0纵轴0.70位置书写文字,画红色当满足条件DD1=1时,在横轴0纵轴0.75位置书写文字,画绿色当满足条件DD1=1时,在横轴0纵轴0.80位置书写文字,COLOR00FFFF。

通达信神奇主图指标公式

通达信神奇主图指标公式

通达信神奇主图指标公式通达信神奇主图指标公式BBI:=(MA(CLOSE,3)+MA(CLOSE,6)+MA(CLOSE,12)+MA(CLOSE,24))/4;UP:BBI + 2.58*STD(BBI,10),COLOR000099,LINETHICK2;LOOW:BBI - 2.58*STD(BBI,10),COLOR000099,LINETHICK2;SAT:=IF((AMOUNT/C)/(HHV(AMOUNT,20)/HHV(C,20))*100>100,100,(AMOUNT/C)/(HHV(AMOUN T,20)/HHV(C,20))*100); AA10:MA(CLOSE,8),COLOR0000FF;AA12:MA(CLOSE,12),COLOR0000FF;BB10:=((ATAN((AA10 - REF(AA10,1))) * 3.1416) * 10);BB12:=((ATAN((AA12 - REF(AA12,1))) * 3.1416) * 10);MA13:=MA(CLOSE,13);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;压⼒:=MA(REF(HHV(C,30),1),2);⽀撑:=MA(REF(LLV(C,30),1),2);AA1:=AMOUNT/V;BB1:=LCC1:=(C-REF(C,1))/REF(C,1)*100>1.2;DD1:=LFF1:=BB1 AND CC1 AND DD1 AND EE1;DRAWTEXT(FF1,(LOW* 0.99),'⽼⿏仓');A51:=3*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1)-2*SMA((C-LLV(L,55))/(HH V(H,55)-LLV(L,55))*100,5,1);⿊马线:=EMA(A51,5);A54:=((C-LLV(L,21))/(HHV(H,21)-LLV(L,21)))*100;趋势线:=(MA(3*SMA(A54,6,1)-2*SMA(SMA(A54,5,1),5,1),2));DRAWTEXT(CROSS(趋势线,0)AND ⿊马线<40,(HIGH* 0.97),'▲⼤⿊马'),COLORYELLOW; LC:=REF(CLOSE,1);RSI:=((SMA(MAX((CLOSE - LC),0),3,1) / SMA(ABS((CLOSE - LC)),3,1)) * 100); FF:=EMA(CLOSE,3);MA15:=EMA(CLOSE,21);DRAWTEXT(CROSS(FF,MA15),(LOW * 0.99),'底背离'),COLORA6E500;DRAWTEXT(CROSS(88,RSI),(HIGH * 1.02),'顶背离'),COLOR1880FF;VAR2:=LLV(LOW,27);VAR3:=HHV(HIGH,34);VAR4:=EMA((CLOSE-VAR2)/(VAR3-VAR2)*4,4)*25;注意买:=IF((VAR4<10),80,100);RSV:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;K:=SMA(RSV,3,1);D:=SMA(K,3,1);J:=3*K-2*D;超跌:=IF(J<0,10,0);BDDD:=LLV(J,2)=LLV(J,8);买⼊:=IF(CROSS(J,REF(J+0.01,1)) AND BDDD AND J<20,30,0);DRAWTEXT(买⼊ AND 注意买=100 AND 超跌=0,LOW,'短线'),COLOR8000FF;MTM:=C-REF(C,1);DX:=100*EMA(EMA(MTM,6),6)/EMA(EMA(ABS(MTM),6),6);买:=IF(LLV(DX,2)=LLV(DX,7) AND COUNT(DX<0,2) AND CROSS(DX,MA(DX,2)),1,0); DRAWTEXT(FILTER(买=1,5),LOW-0.03,'拉升'),COLORFFDE00;A7:=(EMA((OPEN+HIGH+LOW+CLOSE)/4,21)+EMA((OPEN+HIGH+LOW+CLOSE)/4,34)+EMA((OPEN+HIGH+LOW+CLOSE)/4,68))/3;VAR7:=FORCAST(A7,6);MA3K:VAR7,COLORRED,LINETHICK3;MA5K:VAR7,COLORYELLOW,LINETHICK1;STICKLINE(CLOSE> REF(CLOSE,1) ,HIGH,LOW,1,1 ),COLORRED;STICKLINE(CLOSE> REF(CLOSE,1) ,OPEN,CLOSE,6,0 ),COLOR000055;STICKLINE(CLOSE> REF(CLOSE,1) ,OPEN,CLOSE,2.7,0 ),COLOR000077;STICKLINE(CLOSE> REF(CLOSE,1) ,OPEN,CLOSE,2.1,0 ),COLOR000099;STICKLINE(CLOSE> REF(CLOSE,1) ,OPEN,CLOSE,1.5,0 ),COLOR0000BB;STICKLINE(CLOSE> REF(CLOSE,1) ,OPEN,CLOSE,0.9,0 ),COLOR0000DD;STICKLINE(CLOSE> REF(CLOSE,1) ,OPEN,CLOSE,0.3,0 ),COLOR0000FF;STICKLINE(CLOSE= REF(CLOSE,1) ,HIGH,LOW,1,1 ),COLORWHITE;STICKLINE(CLOSE= REF(CLOSE,1) ,OPEN,CLOSE,6,0 ),COLOR555555;STICKLINE(CLOSE= REF(CLOSE,1) ,OPEN,CLOSE,2.7,0 ),COLOR777777;STICKLINE(CLOSE= REF(CLOSE,1) ,OPEN,CLOSE,2.1,0 ),COLOR999999;STICKLINE(CLOSE= REF(CLOSE,1) ,OPEN,CLOSE,1.5,0 ),COLORBBBBBB;STICKLINE(CLOSE= REF(CLOSE,1) ,OPEN,CLOSE,0.9,0 ),COLORDDDDDD;STICKLINE(CLOSE= REF(CLOSE,1) ,OPEN,CLOSE,0.3,0 ),COLORFFFFFF;STICKLINE(CLOSE< REF(CLOSE,1) ,HIGH,LOW,1,1 ),COLORCYAN;STICKLINE(CLOSE< REF(CLOSE,1) ,OPEN,CLOSE,6,0 ),COLOR990000;STICKLINE(CLOSE< REF(CLOSE,1) ,OPEN,CLOSE,2.7,0 ),COLORCC0000;STICKLINE(CLOSE< REF(CLOSE,1) ,OPEN,CLOSE,2.1,0 ),COLORFF4400; STICKLINE(CLOSE< REF(CLOSE,1),OPEN,CLOSE,1.5,0 ),COLORFF8800; STICKLINE(CLOSE< REF(CLOSE,1) ,OPEN,CLOSE,0.9,0 ),COLORFFCC00; STICKLINE(CLOSE< REF(CLOSE,1) ,OPEN,CLOSE,0.3,0 ),COLORCYAN;。

通达信最牛最全主图指标公式

通达信最牛最全主图指标公式

通达信最牛最全主图指标公式MA5:MA(C,5);MA6:=MA(C,6);MA10:MA(C,10);MA20:MA(C,20);A2:=REF(MA20,1);J1:=(MA20-A2)/A2*100;MJ1:=MA(J1,3);MA30:MA(C,30);MA60:MA(C,60);MA120:MA(C,120);乖离2:=(MA20-MA30)/MA30*100;VAR1:=IF(BETWEEN(乖离2,-2,5),2,0);MAX1:=MAX(MA20,MA30);MAX2:=MAX(MAX1,MA60);MIN11:=MIN(MA20,MA30);MIN2:=MIN(MIN11,MA60);K1:=(MAX2/MIN2-1)*100;{粘合度符合条件}VAR2:=IF(K1《=8,1,0);上火车轨:=MA20》MA30 AND MA20》REF(MA20,1)AND MA30》REF(MA30,1)AND MA20-MA30》REF ((MA20-MA30),1) ;STICKLINE(上火车轨,MA20,MA30,0,0),COLORRED;神枪手:=DRAWTEXT(FILTER(上火车轨AND “MACD.DIF”《0.15 AND “MACD.DIF”》REF(“MACD.DIF”,1) AND MA (V,60)》REF(MA(V,60),1) AND MA(V,5)》MA(V,10) AND J1》REF(J1,1) AND(L《=MA20 AND C》MA20 OR (CROSS(MA5,MA20))),5),L*0.98,'←神枪手’);神枪手选股:=FILTER(上火车轨AND “MACD.DIF”《0.15AND “MACD.DIF”》REF(“MACD.DIF”,1)AND MA(V,60)》REF(MA(V,60),1)AND MA(V,5)》MA(V,10)AND J1》REF(J1,1) AND(L《=MA20 AND C》MA20 OR (CROSS(MA5,MA20))),5);{44.40%15240}短线暴张:DRAWTEXT(FILTER((VAR1 OR VAR2)AND MA10》REF(MA10,1)AND COUNT(MA30》REF(MA30,1),3)=3 AND MA30》MA60 AND COUNT(CROSS(MA5,MA30),3) AND J1》MJ1 AND MA(V,5)》MA(V,60)AND MA(V,60)》REF(MA(V,60),1),5),MA60*0.99,'短线暴张’),COLORRED;DRAWTEXT(CROSS(“KDJ.K”(5,2,3),“KDJ.D”(5,2,3))AND “KDJ.D”(5,2,3)《30 AND J1》MJ1 AND MA60》REF(MA60,1)AND COUNT(J1《1,3)》=1 ,L*0.995,'←买入’),COLORYELLOW;DRAWTEXT(CROSS(“KDJ.D”(5,2,3),“KDJ.K”(5,2,3))AND “KDJ.D”(5,2,3)》65 AND J1《MJ1 AND COUNT(J1》1,3)》=1,H*1.005,'←卖出’),COLORGREEN;DRAWTEXT(CROSS(“KDJ.D”(18,9,6),“KDJ.K”(18,9,6))AND “KDJ.D”(18,9,6)》60 AND “KDJ.J”(45,15,15)》90,H*1.03,'←顶’),COLORRED;DRAWTEXT(CROSS(MA5,MA6)AND “KDJ.K”(5,3,3)》=50 AND “KDJ.J”(5,3,3)《31 ,L*0.92,'←再买’),COLORMAGENTA;XL1:=((LLV(LOW,3)= LLV(LOW,60))AND ((CLOSE / REF(CLOSE,1))》= 1.04));XL2:=(((CLOSE - EMA(CLOSE,21)) / EMA(CLOSE,21)) * 100);XL3:=CROSS(XL2,(0 - 20));DRAWTEXT(FILTER(((XL1 》0)AND LOW),5),(LOW - 0.4),'●买点’);DRAWTEXT((XL3 》 0),(LOW - 0.2),'●绝对底部’);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.02),'●出货’),COLOR9000F5;STICKLINE(C》1.098*REF(C,1),C,O,0,0),COLORYELLOW;AAA:=CONST(HHV(H,90));R1:=MA(CLOSE,1);R2:=MA(CLOSE,3);R3:=(MA(R2,1)*1);R4:=(MA(R2,3)*1);DRAWTEXT(CROSS(R3,R4),(LOW-0.1),'进’),COLORYELLOW;LC:=REF(CLOSE,1);RSI:=((SMA(MAX((CLOSE - LC),0),3,1)/ SMA(ABS((CLOSE - LC)),3,1)) * 100);FF:=EMA(CLOSE,3);MA15:=EMA(CLOSE,21);DRAWTEXT(CROSS(88,RSI),(HIGH * 1.02),'出’),COLORGREEN;VARE:=MA(100*(CLOSE-LLV(CLOSE,34))/(HHV (HIGH,34)-LLV(LOW,34)),5)-20;VAR12:=(HIGH+LOW+CLOSE)/3;VAR13:=(VAR12-MA(VAR12,14))/(0.015*AVEDEV(VAR12,14));VAR14:=(VAR12-MA(VAR12,70))/(0.015*AVEDEV (VAR12,70));VAR15:=IF(VAR13》=150 AND VAR13《200 AND VAR14》=150 AND VAR14《200,10,0);VAR16:=IF(VAR13《=-150 AND VAR13》-200 AND VAR14《=-150 AND VAR14》-200,-10,VAR15);VAR17:=(CLOSE-MA(CLOSE,13))/MA(CLOSE,13)*100;VAR18:=100-ABS(VAR17);VAR19:=IF(VAR18《90,VAR18,100);VAR1A:=IF(VARE》0,VARE,0);VAR1B:=IF(VAR14》=200 AND VAR13》=150,15,IF (VAR14《=-200 AND VAR13《=-150,-15,VAR16))+60;VAR1C:=VAR1A》48 AND VAR1B》60 AND VAR19《100;DRAWTEXT(VAR1C AND COUNT(VAR1C,30)=1,HIGH*1.02,'大笔出货’),LINETHICK1,COLORFFCC66;AA1:=AMOUNT/V;BB1:=L《AA1*0.9;CC1:=(C-REF(C,1))/REF(C,1)*100》1.2;DD1:=L《MA(C,5)*0.921;EE1:=V《MA(V,5)*1.5;老鼠仓:=BB1 AND CC1 AND DD1 AND EE1,LINETHICK0;DRAWTEXT(老鼠仓,(LOW* 0.99),'老鼠仓’),COLOR40CCFF;A74:=MA(CLOSE,20);A75:=(CLOSE 》 MA(CLOSE,5));A76:=(MA(CLOSE,5)》 MA(CLOSE,10));A77:=(CLOSE 》 MA(CLOSE,10));A78:=(MA(CLOSE,5)》 MA(CLOSE,20));A79:=(CLOSE 》 MA(CLOSE,20));A710:=REF(A74,1);A711:=(A74 》 A710);AVX:=(((((IF(A75,10,(0 - 10)) + IF(A76,10,(0 - 10))) + IF(A77,10,(0 - 10)))+ IF(A78,10,(0 - 10))) + IF(A79,10,(0 - 10)))+ IF(A711,10,(0 - 10)));DSLX:=(CLOSE / INDEXC);DSLX1:=MA(DSLX,5);DSLX2:=MA(DSLX,10);V1:=MA(VOL,5);V2:=MA(VOL,10);T1:=CONST(IF(C《200 AND ((CROSS(AVX,1) AND (V1 》= V2)) AND (DSLX 》= DSLX1)),1,0));T2:=CONST(IF(C《200 AND ((CROSS(AVX,1) AND (V1 《 V2)) AND (DSLX 》= DSLX1)),1,0));T3:=CONST(IF(C《200 AND ((CROSS(AVX,1) AND (V1 》 V2)) AND (DSLX 《 DSLX1)),1,0));T4:=CONST(IF(C《200 AND ((CROSS(AVX,1) AND (V1 《= V2)) AND (DSLX 《 DSLX1)),1,0));T5:=CONST(IF(C《200 AND ((CROSS(1,AVX) AND (V1 》= V2)) AND (DSLX 》= DSLX1)),1,0));T6:=CONST(IF(C《200 AND ((CROSS(1,AVX) AND (V1 《 V2)) AND (DSLX 》= DSLX1)),1,0));T7:=CONST(IF(C《200 AND ((CROSS(1,AVX) AND (V1 》= V2)) AND (DSLX 《 DSLX1)),1,0));T8:=CONST(IF(C《200 AND ((CROSS(1,AVX) AND (V1 《 V2)) AND (DSLX 《 DSLX1)),1,0));T9:=CONST(IF(C《200 AND ((((AVX 》= 1)AND (REF(AVX,1)》 0)) AND (V1 》= V2)) AND (DSLX 》= DSLX1)),1,0));T10:=CONST(IF(C《200 AND ((((AVX 》= 1) AND (REF(AVX,1)》 0)) AND (V1 《 V2)) AND (DSLX 》= DSLX1)),1,0));T11:=CONST(IF(C《200 AND ((((AVX 》= 1) AND (REF(AVX,1)》0))AND (V1 》= V2))AND (DSLX 《 DSLX1)),1,0));T12:=CONST(IF(C《200 AND ((((AVX 》= 1) AND (REF(AVX,1)》0))AND (V1 《V2))AND (DSLX 《 DSLX1)),1,0));T13:=CONST(IF(C《200 AND ((((AVX 《1)AND (REF(AVX,1)《 0)) AND (V1 》= V2)) AND (DSLX 》= DSLX1)),1,0));T14:=CONST(IF( C《200 AND ((((AVX 《 1) AND (REF(AVX,1)《 0)) AND (V1 《 V2)) AND (DSLX 》= DSLX1)),1,0));T15:=CONST(IF(C《200 AND ((((AVX 《1)AND (REF(AVX,1)《0))AND (V1 》= V2))AND (DSLX 《 DSLX1)),1,0));T16:=CONST(IF(C《200 AND ((((AVX 《1)AND (REF(AVX,1)《0))AND (V1 《V2))AND (DSLX 《 DSLX1)),1,0));T17:=CONST(IF(C》200 AND (CROSS(AVX,1) AND (V1 》= V2)),1,0));T18:=CONST(IF(C》200 AND (CROSS(AVX,1) AND (V1 》= V2)),1,0));T19:=CONST(IF(C》200 AND (CROSS(AVX,1) AND (V1 《 V2)),1,0));T20:=CONST(IF(C》200 AND (CROSS(1,AVX) AND (V1 》= V2)),1,0));T21:=CONST(IF(C》200 AND (CROSS(1,AVX) AND (V1 《 V2)),1,0));T22:=CONST(IF(C》200 AND (((AVX 》= 1)AND (REF(AVX,1)》 0)) AND (V1 》= V2)),1,0));T23:=CONST(IF(C》200 AND (((AVX 》= 1)AND (REF(AVX,1)》 0)) AND (V1 《 V2)),1,0));T24:=CONST(IF(C》200 AND (((AVX 《1)AND (REF(AVX,1)《 0)) AND (V1 》= V2)),1,0));T25:=CONST(IF(C》200 AND (((AVX 《1)AND (REF(AVX,1)《 0)) AND (V1 《 V2)),1,0));DRAWTEXT(T1=1 AND CURRBARSCOUNT=70,AAA-(AAA*0.03),'量能理想,明显走强,中线参与,仓位在2/3左右’),COLORFF00FF ;DRAWTEXT(T2=1 AND CURRBARSCOUNT=70,AAA-(AAA*0.03),'走势趋强,还显不足,短线进场,仓位在1/2左右’),COLORFF00FF ;DRAWTEXT(T3=1 AND CURRBARSCOUNT=70,AAA-(AAA*0.03),'量价良好,没有明显走强,短线进场,仓位1/2左右’),COLORFF00FF ;DRAWTEXT(T4=1 AND CURRBARSCOUNT=70,AAA-(AAA*0.03),'形态尚可,量能不足,未完全走强,短线参与,仓位1/3左右’),COLORFF00FF ;DRAWTEXT(T5=1 AND CURRBARSCOUNT=70,AAA-(AAA*0.03),'形态变坏,重仓者减持大半,清仓者观望’),COLORFF00FF ;,'随大盘一起下跌,明显缩量走势,考虑到风险,减持或清仓’),COLORFF00FF ;DRAWTEXT(T7=1 AND CURRBARSCOUNT=70,AAA-(AAA*0.03),'该股放量下跌,走势明显偏弱,离场观望’),COLORFF00FF ;DRAWTEXT(T8=1 AND CURRBARSCOUNT=70,AAA-(AAA*0.03),'该股缩量下跌,走势偏弱,离场观望。

通达信分时主图通达信指标公式源码

通达信分时主图通达信指标公式源码

通达信分时主图一、先建引用指标FSYY,如果已有的话再里面加上下列几句,我是不断加的。

指数1:"999999$C";指数2:"399001$C";指数3:"399005$C";指数4:"399006$C";二、再建个引用指标FSYY1指数1:"FSYY.指数1#DAY";指数2:"FSYY.指数2#DAY";指数3:"FSYY.指数3#DAY";指数4:"FSYY.指数4#DAY";三、再建分时主图指标均价:SUM(C*V,BARSCOUNT(C))/SUM(V,BARSCOUNT(C)),COLORYELLOW; DRAWICON(FILTER(CROSS(C,DYNAINFO(3)*1.1-0.01),60),C,1);DRAWNUMBER(FILTER(CROSS(C,DYNAINFO(3)*1.1-0.01),60),C*0.98,TIME),COLORYELL OW;DRAWNUMBER(FILTER(CROSS(C,DYNAINFO(3)*1.1-0.01),60),C*0.96,C),COLORMAGENT A;DRAWNUMBER(ISLASTBAR,DYNAINFO(11),DYNAINFO(11)),COLORYELLOW; DRAWNUMBER(ISLASTBAR,DYNAINFO(7),DYNAINFO(7)),COLORWHITE; DRAWTEXT_FIX(1,0.0,0.75,0,'红绿箭头带未来,仅供参考'),COLORGREEN; DRAWTEXT_FIX(1,0.0,0.85,0,STRCAT('上证指数:',CON2STR(FSYY1.指数1,2))),COLORYELLOW;DRAWTEXT_FIX(1,0.3,0.85,0,STRCAT('深圳指数:',CON2STR(FSYY1.指数2,2))),COLORYELLOW;DRAWTEXT_FIX(1,0.0,0.95,0,STRCAT('中小指数:',CON2STR(FSYY1.指数3,2))),COLORYELLOW;DRAWTEXT_FIX(1,0.3,0.95,0,STRCAT('创业指数:',CON2STR(FSYY1.指数4,2))),COLORYELLOW;H1:=MAX(DYNAINFO(3),DYNAINFO(5));L1:=MIN(DYNAINFO(3),DYNAINFO(6));P1:=H1-L1;阻力:=L1+P1*7/8;支撑:=L1+P1*0.5/8;DRAWICON(LONGCROSS(支撑,C,2),C,1);DRAWICON(LONGCROSS(C,阻力,2),C,2);四、注意事项分时主图中的红绿箭头是即时动态的,会根据行情变化的,只能参考。

通达信很牛的批标黑马必抓主图指标公式贴图源码

通达信很牛的批标黑马必抓主图指标公式贴图源码

通达信很牛的批标黑马必抓主图指标公式贴图源码EMA13:EMA(C,5),COLORWHITE; {13-21-34-60}EMA21:EMA(C,13),COLORYELLOW;EMA34:EMA(C,21),COLORFF00FF;EMA60:MA(C,60),COLORFFCC66;{大阴线:大跌超2.3}C2:=REF(C,1);BG:=IF((C2-C)*100/C2>=2.3,1,0) OR IF((O-C)*100/O>=5,1,0){ OR IF((H-L)*100/REF(C,1)>5,1,0)};{第二个条件开盘价过高掉下来}BG2:=IF((H-L)*100/C2>=3.58,1,0);BB1:=L<REF(L,1);{卖点信号}SELL1:=BG AND BB1 ;{大阳线:升幅超2.64}BR:=IF((C-C2)*100/C2>=2.59,1,0) OR IF((C-O)*100/O>=4.5,1,0) OR IF((C-L)*100/L>5,1,0);{第二个条件开盘价太低升上来}STICKLINE(BR,O,C,3,0),COLORRED;{以下条件记住最近一次卖出点}DAY1:=BARSLAST(SELL1);JIA1:=REF(O,DAY1);JIA2:=REF(O,1);BB4:=C>JIA2;BB2:=H>JIA1;{买入信号}BUY1:=BR AND BB2 AND BB4;{记住最后一次买点}DAY2:=BARSLAST(BUY1);{买卖谁先}S1:=DAY1<DAY2;B1:=DAY2<DAY1;{画出卖出信号}{DRAWTEXT(S1,H*1.05,'S'),COLORGREEN;}STICKLINE(S1,O,C,3,0),COLORGREEN;{画出买入信号}{DRAWTEXT(B1,L-0.2,'B'),COLORRED;}STICKLINE(B1,H,L,0.3,0),COLORRED;STICKLINE(B1,O,C,3,1),LINETHICK2,COLORRED;{其它补充1:买点}AA2:=AMOUNT/VOL;BB3:=L<AA2*0.9;CC2:=(C-REF(C,1))/REF(C,1)*100>1.2;DD2:=L<MA(C,6)*0.921;DD1:=L<MA(C,5)*0.921;EE2:=VOL<MA(V,5)*1.5;FF2:=BB3 AND CC2 AND DD2 AND EE2;老鼠仓:=BB3 AND CC2 AND DD1 AND EE2,LINETHICK0,COLOR0099FF;DRAWTEXT(老鼠仓,L*0.97,'老鼠仓'),COLOR0099FF;{DRAWTEXT(FF2,L*0.99,'买点'),COLOR00FFFF;}STICKLINE(FF2,H,L,0.3,0),COLOR00FFFF;{STICKLINE(FF2,O,C,3,1),LINETHICK2,COLOR00FFFF;}{检查买点是否成立}B4:=BARSLAST(FF2);{底点日期}E4:=B4<5;{5日内的线}F4:=E4 AND C>REF(C,1);STICKLINE(F4,H,L,0.3,0),COLOR00FFFF;{其它补充2:卖点}A2:=(C-REF(C,1))/REF(C,1)*100<1.02;A3:=H>MA(C,5)*1.12;AA:= A2 AND A3;DRAWTEXT(AA,H*1.05,'卖点'),COLORFF0000;STICKLINE(AA,H,L,0.3,0),COLORFF0000;{STICKLINE(AA,H,L,3,0),COLORFF0000;};{补充阳光买点}VAR1:=4*SMA((CLOSE-LLV(LOW,5))/(HHV(HIGH,5)-LLV(LOW,5))*100,5,1)-3*SMA(SMA((CLOSE-LLV(LOW,5))/(HHV(HIGH,5)-LLV(LOW,5))*100,5,1),3.2,1);VAR2:=8;CC:=CROSS(VAR1,VAR2);CCC:=CROSS(VAR1,VAR2) AND H>REF(H,1) AND C>REF(C,1) ;DRAWICON(CCC,L*0.99,1);STICKLINE(CC,H,L,0.3,0),COLORRED;STICKLINE(CC,O,C,3,1),LINETHICK2,COLORRED;CF1:=BARSLAST(CC);{买点日期}CF2:=CF1<3;{5日内的线}CF3:=CF2 AND C>REF(C,1);STICKLINE(CF3,O,C,3,0),COLOR00FFFF;CD:=CROSS(VAR2,VAR1);STICKLINE(CD,H,L,0.3,0),COLORYELLOW;STICKLINE(CD,O,C,3,1),LINETHICK2,COLORYELLOW;DRAWTEXT(CD,H*1.01,'准备'),COLORYELLOW;DRAWTEXT(CC,L*0.98,'买'),COLORFF00FF;{输出粉红色的买字};{牛窝}VAR1A:=LLV(LOW,21);VAR2A:=HHV(HIGH,21);AK1:=EMA((((CLOSE - VAR1A) / (VAR2A - VAR1A)) * 100),5);AK:=EMA((((CLOSE - VAR1A) / (VAR2A - VAR1A)) * 50),13);AB:=CROSS(AK1,AK);DRAWTEXT((AB = 1),(LOW * 0.95),'○牛窝'),COLORYELLOW;{主力成本及短期支撑}A:=(3*C+L+O+H)/6;X:=(20*A+19*REF(A,1)+18*REF(A,2)+17*REF(A,3)+16*REF(A, 4)+15*REF(A,5)+14*REF(A,6)+13*REF(A,7)+12*REF(A,8)+11*REF(A,9)+10*REF (A,10)+9*REF(A,11)+8*REF(A,12)+7*REF(A,13)+6*REF(A,14)+5*REF(A,15)+4*REF(A,16)+3*RE F(A,17)+2*REF(A,18)+REF(A,20))/210;S2:=SMA(C,3,1);S6:=SMA(C,5,1);DK:=2*(S2-S6);主力成本:EMA(X,13),LINETHICK1,COLORLIGRAY;短期支撑:LLV(HIGH,30),LINETHICK2,COLORFFCC00;{大胆博、加仓、小心变盘、逃顶}VAR3AA:=IF((CLOSE>REF(CLOSE,1)),88,0);VAR4AA:=IF(((CLOSE)/(REF(CLOSE,1))>1.05) AND ((HIGH)/(CLOSE)<1.01) AND (VAR3AA>0),91,0);DRAWTEXT(FILTER((VAR4AA>90),45),(LOW)*(0.93),'★大胆搏'),COLOR00FFFF;DRAWTEXT(FILTER((VAR4AA>90),35),(LOW)*(0.99000001),'★加仓'),COLOR00FFFF;A1AA:=9;A2AA:=(REF(CLOSE,A1AA+1)<CLOSE);DRAWTEXT(FILTER((A2AA>-0.5),84),(HIGH)*(1.05),'小心变盘'),COLORFFFFFF;VAR6:=REF(C,1);VAR7:=SMA(MAX(C-VAR6,0),6,1)/SMA(ABS(C-VAR6),6,1)*100;DRAWTEXT(CROSS(82,VAR7),H*1.02,'逃顶'),COLORYELLOW;{主力进场}VAR9:=((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27)))*(100);VAR10:=SMA(VAR9,3,1);VAR11:=SMA(VAR10,3,1);VAR12:=SMA(VAR11,3,1);主力出现:DRAWICON(CROSS(VAR11,VAR12) AND (VAR11<40),L*0.98,1);{黑马}A1A:=3*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*1,5,1)-2*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*1,5,1),COLOR330066;A5A:=(HHV(H,60)-C)/(HHV(H,60)-LLV(L,60))*1;DRAWTEXT(CROSS(A1A,EMA(A1A,5))ANDEMA(A1A,5)<A5A,L*0.98,'黑马'),COLORYELLOW;{波段上行和买入};多:EMA(C,3),COLORYELLOW;空:EMA(C,5),COLOR00FF00;均衡:EMA(空,5),COLORWHITE,;VVARF1:=COUNT(CROSS(多,均衡),2)=1;VVARF2:=COUNT(CROSS(空,均衡),2)=1;ZAI:=FILTER(VVARF1 AND VVARF2,2);DRAWTEXT(ZAI,均衡*0.985,' ▲'),COLORRED;VV2:=REF(CLOSE,1);VV3:=SMA((CLOSE-VV2),6,1)/SMA(ABS(CLOSE-VV2),6,1)*100;DRAWICON(REF(VV3,1)>81 AND VV3<80,HIGH,2);VF1:=MA(CLOSE,60)-MA(CLOSE,5)/3.2;DRAWTEXT(IF(CLOSE<VF1 AND VOL/240>MA(VOL,5)/240 AND CLOSE>=REF(CLOSE,1)*1.08 AND CLOSE<MA(CLOSE,13)*1.3,1,0),LOW,'☆'),COLORRED;VVARA:=(CLOSE-REF(OPEN,29))/REF(OPEN,29)*100;VVARB:=EMA(0.667*REF(VVARA,1)+0.333*VVARA,5);DRAWTEXT(IF(VOL>=1.3*MA(VOL,5) AND COUNT(VVARA>=VVARB AND VVARA<-17,3) AND REF(LOW,1)=LLV(LOW,120),1,0),LOW,'★注意买入');VVARR1:=SMA(MAX(CLOSE-REF(C,1),0),6,1)/SMA(ABS(CLOSE-REF(C,1)),6,1)*100;DRAWICON(CROSS(82,VVARR1),HIGH,2);DRAWTEXT(CROSS(82,VVARR1),HIGH,''),COLORYELLOW;VVAR1:=(HIGH+LOW+OPEN+2*CLOSE)/5;VVAR2:=REF(VVAR1,1);VVAR3:=SMA(MAX(VVAR1-VVAR2,0),10,1)/SMA(ABS(VVAR1-VVAR2),10,1)*100;HY3:=IF(COUNT(VVAR3<20,5)>=1 AND COUNT(VVAR1=LLV(VVAR1,10),10)>=1 AND CLOSE>=OPEN*1.038 AND VOL>MA(VOL,5)*1.2,1,0);DRAWTEXT(HY3,LOW,' 注意买入'),COLORRED;。

通达信极品分时主图指标公式

通达信极品分时主图指标公式

通达信极品分时主图指标公式A1:=(VOL/CLOSE)/3;A2:=SUM((IF(((A1>40) AND (CLOSE>(REF(CLOSE,1)))),A1,0)),0);A3:=SUM((IF(((A1>40) AND (CLOSE<(REF(CLOSE,1)))),A1,0)),0);A4:=SUM((IF(((A1<40) AND (CLOSE>(REF(CLOSE,1)))),A1,0)),0);A5:=SUM((IF(((A1<40) AND (CLOSE<(REF(CLOSE,1)))),A1,0)),0);A6:=((A2+A3)+A4)+A5;A7:=IF((BARSTATUS=2),((100*A2)/A6),0);A8:=((IF((BARSTATUS=2),((100*A3)/A6),0)));A9:=((IF((BARSTATUS=2),((100*A4)/A6),0)));A10:=((IF((BARSTATUS=2),((100*A5)/A6),0)));机构买盘:=(A2),LINETHICK2;机构卖盘:=(A3),LINETHICK2;散户买盘:=(A4);散户卖盘:=(A5);DRAWTEXT_FIX(1,0.000,1-0.05,0,STRCAT(STRCAT('【机构买盘】',CON2STR(机构买盘,2)),'万')),COLORRED;DRAWTEXT_FIX(1,0.250,1-0.05,0,STRCAT(STRCAT('【机构卖盘】',CON2STR(机构卖盘,2)),'万')),COLOR00FF00;DRAWTEXT_FIX(1,0.500,1-0.05,0,STRCAT(STRCAT('【散户买盘】',CON2STR(散户买盘,2)),'万')),COLORRED;DRAWTEXT_FIX(1,0.745,1-0.05,0,STRCAT(STRCAT('【散户卖盘】',CON2STR(散户卖盘,2)),'万')),COLOR00FF00;突破:=REF(EMA(C,14),1);A1X:=(EMA(C,10)-突破)/突破*100;多方:=IF(A1X>=0,REF(EMA(C,10),BARSLAST(CROSS(A1X,0))+1),DRAWNULL); 空方:=IF(A1X<0,REF(EMA(C,10),BARSLAST(CROSS(0,A1X))+1),DRAWNULL);STICKLINE(A1X>=0,多方,突破,0,0),COLOR000099;STICKLINE(A1X<0,空方,突破,0,0),COLOR00CC66;最新:CLOSE,LINETHICK1,COLORWHITE;AA:=SUM(AMOUNT,BARSCOUNT(C))/SUM(VOL*100,BARSCOUNT(C));BB:=BETWEEN(C/AA,C+H,C-H);DRAWTEXT( ISLASTBAR AND 最新>REF(最新,1),最新,STRCAT('涨▲',CON2STR(最新,2))),COLORMAGENTA;DRAWTEXT( ISLASTBAR AND 最新<REF(最新,1),最新,STRCAT('跌▼',CON2STR(最新,2))),COLOR00FF00;DRAWTEXT_FIX(CURRBARSCOUNT=1,0,0,0,DYBLOCK),COLORYELLOW;DRAWTEXT_FIX(CURRBARSCOUNT=1,0,0.08,0,GNBLOCK),COLORYELLOW; DRAWTEXT_FIX(CURRBARSCOUNT=1,0,0.14,0,FGBLOCK),COLORYELLOW; 均价:SUM(C*V,240)/SUM(V,240),COLORYELLOW,LINETHICK1;DXJP:=(CLOSE-LLV(LOW,34))/(HHV(HIGH,21)-LLV(LOW,34))*100;FSZX:=(EMA(DXJP,3)-50)*2,COLORGRAY;BGTYU:=IF(DATE<=1150530,1,0);GHYJKU:=BETWEEN((DCLOSE*BGTYU)/(SUM(AMOUNT,BARSCOUNT((DCLOS E*BGTYU)))/SUM(VOL*100,BARSCOUNT((DCLOSE*BGTYU)))),1.05,0.95);VBNH:=IF(GHYJKU=0,MA((DCLOSE*BGTYU),BARSCOUNT((DCLOSE*BGTYU))), (SUM(AMOUNT,BARSCOUNT((DCLOSE*BGTYU)))/SUM(VOL*100,BARSCOUNT((DCLOSE*BGTYU)))));DRAWICON(FSZX<=-95,C,38);DRAWTEXT(CROSS(EXPMA((DCLOSE/VBNH),20),1.04),C,'板'),COLORCYAN;DRAWTEXT(CROSS(EXPMA((DCLOSE/VBNH),20),1.02),C,'追'),COLORYELLOW; DRAWICON(CROSS(EXPMA((DCLOSE/VBNH),120),1.004),C,17);H1:=MAX(DYNAINFO(3),DYNAINFO(5));L1:=MIN(DYNAINFO(3),DYNAINFO(6));P1:=H1-L1;阻力:=L1+P1*7/8,COLORGREEN;支撑:=L1+P1*0.5/8,COLORMAGENTA;DRAWICON(LONGCROSS(支撑,C,2),C,5);DRAWICON(LONGCROSS(C,阻力,2),C,6);VARJ1:=EMA(EMA(CLOSE,13),13);控盘2:=(VARJ1-REF(VARJ1,1))/REF(VARJ1,1)*1000;STJ01:=控盘2<REF(控盘2,1) AND 控盘2>0.5;STJ02:=控盘2>0;BTJ2:=控盘2>REF(控盘2,1) AND 控盘2<-0.2;BTJ22:=控盘2>REF(控盘2,1) AND 控盘2<0 ;JJ:=DYNAINFO(11);P:=55;S:=8;M1:=3;能量:=(EMA(CLOSE,S)-EMA(C,P))*10;空头:=EMA(能量,M1),COLOR00FF00;BTJ1:=(CLOSE-JJ)/JJ<-0.005;BTJ11:=(CLOSE-JJ)/JJ<-0.03;BTJ12:=COUNT(JJ>=REF(JJ,1),5)>=4 AND (CLOSE-JJ)/JJ<0.005;STJ1:=(C-JJ)/JJ>0.005;BTJ3:=CROSS(能量,空头) AND 能量<-0.3;BTJ32:=CROSS(能量,空头) AND 能量<-0.1;STJ31:=CROSS(空头,能量);STJ32:=CROSS(空头,能量) AND 能量>1.618;A:=8;BTJ81:=FILTER(BTJ1 AND BTJ2 AND BTJ3,A);BTJ811:=FILTER(BTJ11 AND BTJ2 AND BTJ3,A);BTJ82:=FILTER(BTJ12 AND BTJ22 AND BTJ32,A);时长:=IF(HOUR>=9 AND HOUR<14 ,1,0);{9点至 14点}捡钱:=BTJ811 AND TIME>15 AND 时长;DRAWICON(捡钱,C,27);AYGB1:=(DVOL/C)/2,NODRAW;AYGB2:=SUM(IF(AYGB1>100 AND CLOSE>REF(CLOSE,1),AYGB1,0),0);AYGB3:=SUM(IF(AYGB1>100 AND CLOSE<REF(CLOSE,1),AYGB1,0),0);AYGB4:=SUM(IF(AYGB1<100 AND CLOSE>REF(CLOSE,1),AYGB1,0),0);AYGB5:=SUM(IF(AYGB1<100 AND CLOSE<REF(CLOSE,1),AYGB1,0),0);AYGB6:=AYGB2+AYGB3+AYGB4+AYGB5;机买:=(AYGB2/AYGB6)*100-100,LINETHICK1,COLORRED;机卖:=(AYGB3/AYGB6)*100-100,LINETHICK1,COLORGREEN;主力差:=机买-机卖;LQH:=主力差>0 AND REF(主力差,1)<=0;DRAWICON(LQH,C,25);JJXX:=IF(BETWEEN(C/(SUM(AMOUNT,0)/SUM(VOL*100,0)),1.05,0.95)=0,MA(C,0 ),(SUM(AMOUNT,0)/SUM(VOL*100,0))),COLORYELLOW;JJXXH:=(JJXX*1.007 ),COLORFF6600;FFLL:=SUM(VOL,6)>REF(MA(VOL,30),1)*10;HHPP:=((HHV(CLOSE,BARSCOUNT(CLOSE))-LLV(CLOSE,BARSCOUNT(CLOSE )))/CLOSE)<1;HHZZ:=HHPP AND FFLL AND (C>JJXXH);TTPP2:=FILTER(HHZZ,100);DRAWICON(TTPP2,C,26);ZS:=DYNAINFO(3);KP:=DYNAINFO(4);ZX:=DYNAINFO(7);ZG:=DYNAINFO(5);ZD:=DYNAINFO(6);分时均价线:SUM(C*V,240)/SUM(V,240),COLORYELLOW;昨高:='FSKY.ZH#DAY';昨低:='FSKY.ZL#DAY';。

通达信指标公式源码最好用的主图指标

通达信指标公式源码最好用的主图指标

通达信指标公式源码最好用的主图指标通达信是一个非常受欢迎的股票分析软件,它提供了丰富的技术指标供投资者使用。

以下是一些通达信中常用的主图指标以及它们的源码。

1.移动平均线(MA):MA是一种常用的趋势指标,通过计算一段时间内的股价平均值来展示价格走势。

通达信中的MA指标源码如下:```MA(CLOSE,N):=MA(CLOSE,N);```其中,CLOSE表示收盘价,N表示计算的周期。

2.相对强弱指标(RSI):RSI是一种用于判断股票超买超卖情况的指标,通达信中的RSI指标源码如下:```RSI(CLOSE,N):=SMA(MAX(CLOSE-REF(CLOSE,1),0),N,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),N,1)*100;```其中,CLOSE表示收盘价,N表示计算的周期。

3.随机指标(KDJ):KDJ指标是一种通过计算最高价、最低价和收盘价的相对关系来判断超买超卖情况的指标,通达信中的KDJ指标源码如下:```RSV:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;K:SMA(RSV,M1,1);D:SMA(K,M2,1);J:3*K-2*D;```其中,CLOSE表示收盘价,LOW表示最低价,HIGH表示最高价,N、M1和M2表示计算的周期。

4.平均成交量(MAVOL):MAVOL是一种用于衡量成交量的指标,通达信中的MAVOL指标源码如下:```MA(CLCV,N):=MA(CLCV,N);```其中,CLCV表示成交量,N表示计算的周期。

5.动量指标(MTM):MTM是一种用于衡量价格变动速度的指标,通达信中的MTM指标源码如下:```MTM(CLOSE,N):=CLOSE-REF(CLOSE,N);```其中,CLOSE表示收盘价,N表示计算的周期。

以上是一些通达信中常用的主图指标及其源码。

这些指标可以帮助投资者分析股票的趋势、超买超卖情况、成交量以及价格变动速度等重要因素,从而作出更明智的投资决策。

通达信神奇分时主图可以精确指标公式

通达信神奇分时主图可以精确指标公式

通达信,神奇分时,主图,指标公式E5:=EMA(C,5);E13:=EMA(C,13);DRAWNUMBER(ISLASTBAR ,C,C),COLORMAGENTA; DRAWBAND(E5,RGB(200,0,0),E13,RGB(0,200,0));A1:EMA((EMA(C,1)+EMA(C,3)+EMA(C,5))/3,3),COLOR1010FF;A2:EMA((EMA(C,3)+EMA(C,5)+EMA( C,7))/3,3),COLOR1020FF;A3:EMA((EMA(C,5)+EMA(C,7)+EMA( C,9))/3,3),COLOR1030FF;A4:EMA((EMA(C,7)+EMA(C,9)+EMA( C,11))/3,3),COLOR1040FF;A5:EMA((EMA(C,9)+EMA(C,11)+EMA( C,13))/3,3),COLOR1050FF; A6:EMA((EMA(C,11)+EMA(C,13)+EMA( C,15))/3,3),COLOR1060FF; A7:EMA((EMA(C,13)+EMA(C,15)+EMA( C,17))/3,3),COLOR1070FF; A8:EMA((EMA(C,15)+EMA(C,17)+EMA( C,19))/3,3),COLOR1080FF; A9:EMA((EMA(C,17)+EMA(C,19)+EMA( C,21))/3,3),COLOR1080EF; A10:EMA((EMA(C,19)+EMA(C,21)+EMA( C,23))/3,3),COLOR10C0FF; A11:EMA((EMA(C,21)+EMA(C,23)+EMA( C,25))/3,3),COLOR10E0FF; A15:=A-(A1-A*0.997),COLORFF1010;A16:A-(A2-A),COLORFF2010;A17:A-(A3-A),COLORFF3010;A18:A-(A4-A),COLORFF4010;A19:A-(A5-A),COLORFF5010;A20:A-(A6-A),COLORFF6010;A21:A-(A7-A),COLORFF7010;A22:A-(A8-A),COLORFF8010;A23:A-(A9-A),COLORFF9010;A24:A-(A10-A),COLORFFC010;A25:A-(A11-A*0.997),COLORFFE010;FD:=(H-L)/3;OPEN1:=O>FD*2+L;OPEN3:=O<FD+L;OPEN2:=NOT(OPEN1 OR OPEN3);CLOSE1:=C>FD*2+L;CLOSE3:=C<FD+L;CLOSE2:=NOT(CLOSE1 OR CLOSE3);DFZD:=CLOSE1 OR (OPEN3 AND CLOSE2);WQS1:=OPEN2 AND CLOSE2;KFZD:=NOT(DFZD OR WQS1);ZD:=(H+L)/2;QSXS:=ZD>REF(H,1);QSXX:=ZD<REF(L,1);WQS2:=NOT(QSXS OR QSXX);ZTDL:=V>REF(V,1)*1.1;FTDL:=V<REF(V,1)*0.7;ZTDL2:=ZTDL AND FTDL<1;FTDL2:=FTDL AND ZTDL<1;MFI1:=(H-L)/(V/10000);MFI2:=(H-L)/(V/1000000);ZMFI1:=MFI1>REF(MFI1,1);ZMFI2:=MFI2>REF(MFI2,1);ZMFI:=ZMFI1 OR ZMFI2;FMFI:=NOT(ZMFI);LD:=ZTDL2 AND ZMFI;ST:=FTDL2 AND FMFI;WZ:=FTDL2 AND ZMFI;QF:=ZTDL2 AND FMFI;S11:=DFZD AND QSXS ;S22:=KFZD AND QSXX ;S33:=DFZD AND QSXX;S44:=KFZD AND QSXS;S55:=DFZD AND WQS2;S66:=KFZD AND WQS2;S77:=WQS1 AND (QSXS OR QSXX OR WQS2);DRAWKLINE(H,O,L,C);CC:=HHV(IF(TIME<103000,C,0),0);VV:=HHV(IF(TIME<103000,V,0),0);ZF:=CC/DYNAINFO(3)<1.05;XH:=C>=CC AND V>=VV AND TIME>=103000 AND DYNAINFO(7)=C;GL:=FILTER(XH,100);STICKLINE(GL,DYNAINFO(7)*0.98,DYNAINFO(7)*0.999,10,0) COLOR0000FF; DRAWTEXT(GL,DYNAINFO(7)*0.99,'突破'),COLORYELLOW,LINETHICK1;TBX:=REF(EMA(C,14),1);A1X:=(EMA(C,10)-TBX)/TBX*100;DFX:=IF(A1X>=0,REF(EMA(C,10),BARSLAST(CROSS(A1X,0))+1),DRAWNULL); KFX:=IF(A1X<0,REF(EMA(C,10),BARSLAST(CROSS(0,A1X))+1),DRAWNULL);最新:C,LINETHICK1,COLORFFFF00;MA30:=EMA(CLOSE,30);H1:=MAX(DYNAINFO(3),DYNAINFO(5));L1:=MIN(DYNAINFO(3),DYNAINFO(6));P1:=H1-L1;阻力:L1+P1*7/8,COLORFFFF00,DOTLINE;支撑:L1+P1*0.5/8,COLOR0000FF,DOTLINE;现价:=CLOSE,COLORWHITE,LINETHICK1;日时转换:=IF(PERIOD=5,120,240);QZS:=(EMA(CLOSE,10)+EMA(CLOSE,32))/2;VAR11:=(EMA(CLOSE,30)+EMA(CLOSE,72))/2;VAR22:=(EMA(VOL,10)+EMA(VOL,32))/2;VAR33:=(VAR11+VAR22)/2;VAR44:=EMA(VAR33,30);VAR55:=EMA(VAR33,60);VAR66:=EVERY(VAR11>REF(VAR11,1),5) AND EVERY(VAR44>REF(VAR44,1),5); DRAWBAND(VAR11,RGB(150,30,30),EMA(VAR11,60),RGB(0,110,30));NXX:EMA(C,120),COLOR0080FF,LINETHICK3;DRAWTEXT(BARSTATUS=2,NXX,'牛熊线'),COLORFFFFFF;牵引线:VAR11,COLOR4B4B4B,DOTLINE;强弱线:EMA(VAR11,日时转换),POINTDOT,COLOR0080FF;趋势关注:IF(CROSS(VAR11,EMA(VAR11,60)) AND VAR66,1,0),NODRAW,COLORRED; 量价关注:IF(CROSS(VAR33,VAR55) AND VAR66,1,0),NODRAW,COLORWHITE;冲击量:IF(VAR33>VAR55 AND VAR66,1,0),NODRAW,COLORYELLOW;强势区:IF(VAR11>强弱线,1,DRAWNULL),NODRAW,COLORRED;止损区:IF(VAR11<强弱线,1,DRAWNULL),NODRAW,COLORGREEN;STICKLINE(QZS>VAR11,QZS,VAR11,0,0),COLORMAGENTA;STICKLINE(冲击量=1,QZS,VAR11,0,0),COLORYELLOW;STICKLINE(CROSS(支撑,现价),支撑,阻力,1,0),COLORYELLOW;DRAWKLINE(H,O,L,C);DRAWICON(LONGCROSS(支撑,现价,2),L,1),COLORYELLOW;{吸}DRAWICON(LONGCROSS(现价,阻力,2),H,2),COLORGREEN;{抛};DRAWICON(趋势关注=1,EMA(VAR11,60),13);DRAWTEXT(量价关注=1,EMA(VAR11,60),'★'),COLORWHITE;均价:SUM(V*C,0)/SUM(V,0),COLORFF00FF;DRAWTEXT(CURRBARSCOUNT=4,均价,'均'),COLORFFFFFF,LINETHICK1;IF(C>=REF(C,1),C,DRAWNULL),LINETHICK1,COLORRED;AA:=SUM(AMOUNT,BARSCOUNT(C))/SUM(VOL*100,BARSCOUNT(C));BB:=BETWEEN(C/AA,C+H,C-H);DRAWICON(ISLASTBAR AND C>REF(C,1),C,1);DRAWICON(ISLASTBAR AND C<REF(C,1),C,2);DXJP:=(CLOSE-LLV(LOW,34))/(HHV(HIGH,21)-LLV(LOW,34))*100;FSZX:=(EMA(DXJP,3)-50)*2,COLORGRAY;BGTYU:=IF(DATE<=1150530,1,0);GHYJKU:=BETWEEN((DCLOSE*BGTYU)/(SUM(AMOUNT,BARSCOUNT((DCLOSE*BGT YU)))/SUM(VOL*100,BARSCOUNT((DCLOSE*BGTYU)))),1.05,0.95);VBNH:=IF(GHYJKU=0,MA((DCLOSE*BGTYU),BARSCOUNT((DCLOSE*BGTYU))),(SUM (AMOUNT,BARSCOUNT((DCLOSE*BGTYU)))/SUM(VOL*100,BARSCOUNT((DCLOSE*B GTYU)))));DRAWICON(FSZX<=-95,C,38);DRAWTEXT(CROSS(EXPMA((DCLOSE/VBNH),20),1.04),C,'板'),COLORCYAN; DRAWTEXT(CROSS(EXPMA((DCLOSE/VBNH),20),1.02),C,'追'),COLORYELLOW; DRAWICON(CROSS(EXPMA((DCLOSE/VBNH),120),1.004),C,17);VARJ1:=EMA(EMA(CLOSE,13),13);控盘2:=(VARJ1-REF(VARJ1,1))/REF(VARJ1,1)*1000;STJ01:=控盘2<REF(控盘2,1) AND 控盘2>0.5;STJ02:=控盘2>0;BTJ2:=控盘2>REF(控盘2,1) AND 控盘2<-0.2;BTJ22:=控盘2>REF(控盘2,1) AND 控盘2<0 ;JJ:=DYNAINFO(11);P:=55;S:=8;M1:=3;能量:=(EMA(CLOSE,S)-EMA(C,P))*10;空头:=EMA(能量,M1),COLOR00FF00;BTJ1:=(CLOSE-JJ)/JJ<-0.005;BTJ11:=(CLOSE-JJ)/JJ<-0.03;BTJ12:=COUNT(JJ>=REF(JJ,1),5)>=4 AND (CLOSE-JJ)/JJ<0.005;STJ1:=(C-JJ)/JJ>0.005;BTJ3:=CROSS(能量,空头) AND 能量<-0.3;BTJ32:=CROSS(能量,空头) AND 能量<-0.1;STJ31:=CROSS(空头,能量);STJ32:=CROSS(空头,能量) AND 能量>1.618;A:=8;BTJ81:=FILTER(BTJ1 AND BTJ2 AND BTJ3,A);BTJ811:=FILTER(BTJ11 AND BTJ2 AND BTJ3,A);BTJ82:=FILTER(BTJ12 AND BTJ22 AND BTJ32,A);AYGB1:=(DVOL/C)/2,NODRAW;AYGB2:=SUM(IF(AYGB1>100 AND CLOSE>REF(CLOSE,1),AYGB1,0),0);AYGB3:=SUM(IF(AYGB1>100 AND CLOSE<REF(CLOSE,1),AYGB1,0),0);AYGB4:=SUM(IF(AYGB1<100 AND CLOSE>REF(CLOSE,1),AYGB1,0),0);AYGB5:=SUM(IF(AYGB1<100 AND CLOSE<REF(CLOSE,1),AYGB1,0),0);AYGB6:=AYGB2+AYGB3+AYGB4+AYGB5;机买:=(AYGB2/AYGB6)*100-100,LINETHICK1,COLORRED;机卖:=(AYGB3/AYGB6)*100-100,LINETHICK1,COLORGREEN;主力差:=机买-机卖;LQH:=主力差>0 AND REF(主力差,1)<=0;DRAWICON(LQH,C,25);JJXX:=IF(BETWEEN(C/(SUM(AMOUNT,0)/SUM(VOL*100,0)),1.05,0.95)=0,MA(C,0),(S UM(AMOUNT,0)/SUM(VOL*100,0))),COLORYELLOW;JJXXH:=(JJXX*1.007 ),COLORFF6600;FFLL:=SUM(VOL,6)>REF(MA(VOL,30),1)*10;HHPP:=((HHV(CLOSE,BARSCOUNT(CLOSE))-LLV(CLOSE,BARSCOUNT(CLOSE)))/CLOSE)<1;HHZZ:=HHPP AND FFLL AND (C>JJXXH);TTPP2:=FILTER(HHZZ,100);DRAWICON(TTPP2,C,26);时间:=TIME=100000;N:=BARSLAST(时间);常数:CONST(IF(N=0,C,REF(C,N))),COLORFFFFFF,DOTLINE; CS1:=CONST(IF(N,HHV(H,0),REF(HHV(H,0),N)));CS2:=CONST(IF(N,LLV(L,0),REF(LLV(L,0),N))); STICKLINE(时间=1,CS1,CS2,-1,0),COLORFFFFFF; CONST(IF(N,LLV(L,0),REF(LLV(L,0),N))),COLOR888888; CONST(IF(N,HHV(L,0),REF(HHV(L,0),N))),COLOR888888; 期货培训,股票培训:/。

通达信指标公式源码 精准的K线主图公式源码

通达信指标公式源码 精准的K线主图公式源码

BBI:(MA(C,3)+MA(C,6)+MA(C,12)+MA(C,24))/4;MA(C,N1);MA(C,N2);MA(C,N3),LINETHICK2;MA(C,N4),COLORLIRED,LINETHICK2; 买线:=EMA(C,2);卖线:=EMA(SLOPE(C,21)*20+C,42);中:=(MA(CLOSE,30)+MA(C,72))/2,COLOR999999,LINETHICK0;HLY1:=中*1.1,POINTDOT,COLOR999999,LINETHICK0;VAR61:=(CLOSE*2+HIGH+LOW)/4;VAR62:=EMA(VAR61,3);VAR63:=EMA(VAR62,6);L1:=EMA(VAR61,3),LINETHICK0;L2:=EMA(VAR62,4),LINETHICK0;L3:=EMA(VAR63,5),LINETHICK0;{正常上涨}STICKLINE(C>=O,H,L,0,0 ),COLOR0000FF; {红色}STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,3.2,0) ,COLOR000055;STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,2.6,0) ,COLOR000077;STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,1.9,0) ,COLOR000099;STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,1.1,0) ,COLOR0000BB;STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,0.2,0) ,COLOR0000FF; {STICKLINE(CLOSE>OPEN,CLOSE,OPEN,1.2,0) ,COLOR0000EE;STICKLINE(CLOSE>OPEN,CLOSE,OPEN,0.4,0) ,COLOR0000FF;}{正常下跌}STICKLINE(OPEN>=CLOSE,H,L,0,0 ),COLORFFFF00; {天蓝}STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,3.2,0 ),COLORFF5500;STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,2.6,0 ),COLORFF7700;STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,1.9,0 ),COLORFF9900;STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,1.1,0 ),COLORFFBB00;STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,0.2,0 ),COLORFFDD00; {STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,1.2,0 ),COLORFFEE00; STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,0.4,0 ),COLORFFFF00;}{整理下跌区}{STICKLINE(L1<L2,H,LOW,0 ,0 ),COLORFFFFFF;{灰色}{STICKLINE(L1<L2,CLOSE ,OPEN,3.0,0 ),COLOR555555;STICKLINE(L1<L2,CLOSE ,OPEN,2.5,0 ),COLOR777777;STICKLINE(L1<L2,CLOSE ,OPEN,1.9,0 ),COLOR999999;STICKLINE(L1<L2,CLOSE ,OPEN,1.2,0 ),COLORBBBBBB;STICKLINE(L1<L2,CLOSE ,OPEN,0.4,0 ),COLORDDDDDD;}{STICKLINE(L1<L2,CLOSE ,OPEN,3,0 ),COLORFFEE00;STICKLINE(L1<L2,CLOSE ,OPEN,2,0 ),COLORFFFF00;}{下跌开始}VAR44:=REF(L1,1)>L1 AND L1>L2;STICKLINE(VAR44,H,LOW,0,0 ),COLORFF0000; {蓝色}{STICKLINE(VAR44,CLOSE,OPEN,3.0,0) ,COLOR550000;STICKLINE(VAR44,CLOSE,OPEN,2.5,0) ,COLOR660000;}STICKLINE(VAR44,CLOSE,OPEN,3.2,0) ,COLOR660000;STICKLINE(VAR44,CLOSE,OPEN,2.6,0) ,COLORAA0000;STICKLINE(VAR44,CLOSE,OPEN,1.9,0) ,COLOREE1100;STICKLINE(VAR44,CLOSE,OPEN,1.1,0) ,COLORFF3300;STICKLINE(VAR44,CLOSE,OPEN,0.2,0) ,COLORFF5500;{顶部钝化区}STICKLINE((CLOSE >= HLY1),H,LOW,0 ,0),COLORFF00FF;{粉色}STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,3.2,0),COLOR770077;STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,2.6,0),COLORAA00AA;STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,1.9,0),COLORDD00DD;STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,1.1,0),COLORFF22FF;STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,0.2,0),COLORFF66FF;{STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,3,0),COLORFFDDFF;STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,2,0),COLORFFEEFF;}{单边下跌}STICKLINE(买线<卖线,H,LOW,0,0 ),COLOR00FF00; {绿色}STICKLINE(买线<卖线,CLOSE ,OPEN,3.2,0),COLOR004400;STICKLINE(买线<卖线,CLOSE ,OPEN,2.6,0),COLOR005500;STICKLINE(买线<卖线,CLOSE ,OPEN,1.9,0),COLOR007700;STICKLINE(买线<卖线,CLOSE ,OPEN,1.1,0),COLOR009900;STICKLINE(买线<卖线,CLOSE ,OPEN,0.2,0),COLOR00CC00;{STICKLINE(买线<卖线,CLOSE ,OPEN,3,0),COLOR00DD00;STICKLINE(买线<卖线,CLOSE ,OPEN,2,0),COLOR00FF00;}{向上变盘}STICKLINE(CROSS(买线,卖线),H,L,0,0),COLOR0033DD;{橘黄}STICKLINE(CROSS(买线,卖线),C,OPEN,3.2,0),COLOR000077;STICKLINE(CROSS(买线,卖线),C,OPEN,2.6,0),COLOR003399;STICKLINE(CROSS(买线,卖线),C,OPEN,1.9,0),COLOR0033DD;STICKLINE(CROSS(买线,卖线),C,OPEN,1.1,0),COLOR0055FF;STICKLINE(CROSS(买线,卖线),C,OPEN,0.2,0),COLOR0099FF;{向下变盘}STICKLINE(CROSS(卖线,买线),H,L,0,0),COLOR00FFFF;{黄色}STICKLINE(CROSS(卖线,买线),C,OPEN,3.2,0),COLOR008888;STICKLINE(CROSS(卖线,买线),C,OPEN,2.6,0),COLOR00AAAA;STICKLINE(CROSS(卖线,买线),C,OPEN,1.9,0),COLOR00CCCC;STICKLINE(CROSS(卖线,买线),C,OPEN,1.1,0),COLOR00EEEE;STICKLINE(CROSS(卖线,买线),C,OPEN,0.2,0),COLOR44FFFF;N1,N2,N3,N4:分别为:5,10,30,60。

【通达信】很好的主图源码,不要错过哦

【通达信】很好的主图源码,不要错过哦

【通达信】很好的主图源码,不要错过哦MA5:MA(C,5)LINETHICK1;MA10:MA(C,10) ,LINETHICK1;MA20:MA(C,20) ,LINETHICK1;MA30:MA(C,30),LINETHICK1;MA62:MA(C,62),LINETHICK1 ;MA133:MA(C,133),LINETHICK1;DIF2:=(EMA(CLOSE,252)-EMA(CLOSE,546));DEA2:=EMA(DIF2,189);MACD:=(DIF2-DEA2)/2,STICK,LINETHICK9,COLORGREEN;DIF1:=(EMA(CLOSE,60)-EMA(CLOSE,130));DEA1:=EMA(DIF1,40);昨月:=MACD.DIF#MONTH>REF(MACD.DIF#MONTH,1) AND MACD#MONTH>0 AND MACD#MONTH>0;MACD月:=MACD.DIF#MONTH>MACD.DEA#MONTH AND MACD.DIF#MONTH>0 AND 昨月;DRAWICON(MACD月,L-0.25,25),COLORYELLOW,LINETHICK3;DRAWKLINE(H,O,L,C);ZKP:=IF(C>REF(C,1),REF(C,1),DRAWNULL);ZSP:=IF(C>REF(C,1),C,DRAWNULL);DKP:=IF(C<=REF(C,1),REF(C,1),DRAWNULL);DSP:=IF(C<=REF(C,1),C,DRAWNULL);DRAWKLINE(H,DKP,L,DSP);STICKLINE(C<=REF(C,1),DKP,DSP,3.05,0),COLORBLUE;STICKLINE(C<=REF(C,1),DKP,DSP,2.2,0),COLORFF7700;STICKLINE(C<=REF(C,1),DKP,DSP,1.5,0),COLORFF9900;STICKLINE(C<=REF(C,1),DKP,DSP,0.5,0),COLORFFBB00;DRAWKLINE(H,ZKP,L,ZSP);STICKLINE(C>REF(C,1),ZKP,ZSP,3.05,0),COLOR000099;STICKLINE(C>REF(C,1),ZKP,ZSP,2.2,0),COLOR0000CC;STICKLINE(C>REF(C,1),ZKP,ZSP,1.5,0),COLOR0000FF;STICKLINE(C>REF(C,1),ZKP,ZSP,0.5,0),COLORCC66FF;STICKLINE(V/REF(V,1)>2 AND CLOSE>=OPEN,ZKP,ZSP,1,0),COLORYELLOW;DRAWRECTREL(0,500,147,999.4,IF(120,RGB(10,0,0),0));超B:=L2_AMO(0,2)/10000.0;大B:=L2_AMO(1,2)/10000.0;中B:=L2_AMO(2,2)/10000.0;小B:=L2_AMO(3,2)/10000.0;超S:=L2_AMO(0,3)/10000.0;大S:=L2_AMO(1,3)/10000.0;中S:=L2_AMO(2,3)/10000.0;小S:=L2_AMO(3,3)/10000.0;TESTSKIP(NOT(超B OR 大B OR 中B OR 小B OR 超S OR 大S OR 中S OR 小S)!=0);大宗进:=(超B)+(大B),NODRAW;大宗出:=(超S)+(大S),NODRAW;非大宗进:=(中B)+(小B),NODRAW;非大宗出:=(中S)+(小S),NODRAW;大宗进限制:=IF((超B+大B)=0,0,大宗进);大宗出限制:=IF((超S+大S)=0,0,大宗出);非大宗进限制:=IF(中B+小B=0,0,非大宗进);非大宗出限制:=IF(中S+小S=0,0,非大宗出);主力净流入:=(超B+大B)-(超S+大S),COLORRED,NODRAW;散户净流入:=(中B+小B)-(中S+小S),COLORRED,NODRAW;净流入:=(超B+大B+中B+小B)-(超S+大S+中S+小S),COLORRED,NODRAW;大单流入:=(超B+大B)/(超B+大B+超S+大S)*100,NODRAW;大单流入限制:=IF((超B+大B+超S+大S)=0,0,大单流入);大单流出比:=(超S+大S)/(超B+大B+超S+大S)*100,NODRAW;大单流出限制:=IF((超B+大B+超S+大S)=0,0,大单流出比);总流入比:=(超B+大B+中B+小B)/(超B+大B+中B+小B+超S+大S+中S+小S)*100,NODRAW;总流出比:=(超S+大S+中S+小S)/(超B+大B+中B+小B+超S+大S+中S+小S)*100,NODRAW;成交总量:=(超B+大B+中B+小B+超S+大S+中S+小S),NODRAW;机构参与度:=(超B+超S+大B+大S)/成交总量*100,COLORYELLOW,NODRAW;大单强度:=(超B+大B-超S-大S)/成交总量*100,COLORYELLOW,NODRAW;大单强度限制:=IF(大单强度=0,-100,大单强度);大单强度比:=IF(大单强度>=0,(大单强度限制+100)/2,100-ABS((大单强度限制-100)/2)),NODRAW;超单强度:=(超B-超S)/(超B+超S)*100,COLORYELLOW,NODRAW;超单强度限制:=IF(超单强度=0,-100,超单强度);超单强度比:=IF(超单强度>0,(超单强度限制+100)/2,IF(超单强度<0,100-ABS((超单强度限制-100)/2),0)),NODRAW;DAZHIV:=CONST(MAX(ABS(大宗进),MAX(ABS(大宗出),MAX(ABS(非大宗进),ABS(非大宗出))))),NODRAW;DRAWRECTREL(0,CONST(930-(ABS(大宗进)*250/DAZHIV)),35,950,IF(CONST(大宗进>0),RGB(255,0,0),RGB(23,125,255)));DRAWRECTREL(37,CONST(930-(ABS(大宗出)*250/DAZHIV)),72,950,IF(CONST(大宗出>0),RGB(23,125,255),RGB(255,0,0)));DRAWRECTREL(75,CONST(930-(ABS(非大宗进)*250/DAZHIV)),110,950,IF(CONST(非大宗进>0),RGB(255,0,0),RGB(23,125,255)));DRAWRECTREL(112,CONST(930-(ABS(非大宗出)*250/DAZHIV)),147,950,IF(CONST(非大宗出>0),RGB(23,125,255),RGB(255,0,0)));DRAWRECTREL(150,CONST(940-(ABS(净流入)*250/DAZHIV))-20,190,950,IF(CONST(净流入>0),RGB(200,0,0),RGB(0,125,50)));DRAWTEXT_FIX(CURRBARSCOUNT=1,0.0001,0.9,0,STRCAT('' ,CON2STR(大宗进/1,0))),COLORYELLOW;DRAWTEXT_FIX(CURRBARSCOUNT=1,0.036,0.9,0,STRCAT('', CON2STR(大宗出/1,0))),COLORYELLOW;DRAWTEXT_FIX(CURRBARSCOUNT=1,0.074,0.9,0,STRCAT('', CON2STR(非大宗进/1,0))),COLORYELLOW;DRAWTEXT_FIX(CURRBARSCOUNT=1,0.111,0.9,0,STRCAT('', CON2STR(非大宗出/1,0))),COLORYELLOW;DRAWTEXT_FIX(CURRBARSCOUNT=1,0.150,0.9,0,STRCAT('', CON2STR(净流入/1,0))),COLORYELLOW;DRAWTEXT_FIX(1,0.000,0.99,0,STRCAT(STRCAT('主力',CON2STR(主力净流入,0)),'万')),COLORMAGENTA;DRAWTEXT_FIX(1,0.078,0.99,0,STRCAT(STRCAT('散户',CON2STR(散户净流入,0)),'万')),COLORCYAN;DRAWTEXT_FIX(CURRBARSCOUNT=1,0.145,0.99,0,'净流入:(万)'),COLORYELLOW;主力买力度:=LARGEINTRDVOL*1000/VOL;主力卖力度:=LARGEOUTTRDVOL*1000/VOL;AAD:=CONST(MAX(ABS(主力买力度),ABS(主力卖力度)))*4,NODRAW;DRAWRECTREL(0,515,CONST(ABS(主力买力度)*560/AAD),568,IF(CONST(主力买力度)>0,RGB(255,0,0),RGB(0,50,0)));DRAWRECTREL(0,570,CONST(ABS(主力卖力度)*560/AAD),623,IF(CONST(主力卖力度)>0,RGB(0,50,0),RGB(255,0,0)));DRAWTEXT_FIX(1,0,0.524,0,STRCAT('主买力度:',CON2STR(主力买力度,0))),COLORYELLOW;DRAWTEXT_FIX(1,0,0.576,0,STRCAT('主卖力度:',CON2STR(主力卖力度,0))),COLORYELLOW;。

通达信指标公式源码 分时主图,打板.做t.追涨,全天候(简单图)

通达信指标公式源码 分时主图,打板.做t.追涨,全天候(简单图)

TT:=BARSCOUNT(C);{取得有效收盘价}
均价黄:SUM(C*V,TT)/SUM(V,TT),LINETHICK1,COLOR00FFE1;{分时均线的取值}
量两步:=MA(V,5)>REF(MA(V,5),1) AND REF(MA(V,5),1)>REF(MA(V,5),2);
价两步:= C>=REF(C,1) AND REF(C,1)>REF(C,2);
价上岗量破5:=C>均价黄AND V>MA(V,5);
量起爆:=V>=REF(V,1)*2 ;
价创新高:=C>=HHV(C,0);
量创新高:=V>=HHV(V,0);
对昨日涨幅:=C/DYNAINFO(3)<=1.02;{涨幅控制2个点以内}
每日一点:=量两步AND 价两步AND 价上岗量破5 AND 量起爆AND 价创新高AND 量创新高AND 对昨日涨幅;
{计算收益、已爆分钟}
VC:=BARSSINCE(每日一点)+1;
首次起爆价:REF(C,VC-1),NODRAW;
今天收益:(DYNAINFO(7)-首次起爆价)/首次起爆价*100,NODRAW;
起爆时间:REF(TIME/10000,VC),NODRAW;
已爆分钟:VC-1,NODRAW;
首次起爆量:=REF(VOL,VC-1);
DRAWICON(已爆分钟>=2,DYNAINFO( 3)-0.1,11);{出现金手指,至少已经确认2分钟了};。

通达信指标公式源码量柱擒涨停+黄金柱+涨停时间窗主图

通达信指标公式源码量柱擒涨停+黄金柱+涨停时间窗主图

C2:=REF(C,1);涨停:=IF((C-C2)*100/C2>=(10-0.01*100/C2),1,0);STICKLINE(涨停,OPEN,CLOSE,-1,0),COLORYELLOW;STICKLINE(涨停,H,L,0,0),COLORYELLOW;跌停:=IF((C2-C)*100/C2>=(10-0.01*100/C2),1,0);STICKLINE(跌停,OPEN,CLOSE,-1,0),COLORBLUE;STICKLINE(跌停,H,L,0,1),COLORBLUE;大阳线:=IF((C-C2)*100/C2>=5,1,0)&&IF((C-C2)*100/C2<(10-0.01*100/C2),1,0) OR IF((C-O)*100/O>=5,1,0)&&IF((C-C2)*100/C2<(10-0.01*100/C2),1,0); STICKLINE(大阳线,OPEN,CLOSE,-1,0),COLORRED;STICKLINE(大阳线,H,L,0,1),COLORRED;大阴线:=IF((C2-C)*100/C2>=5,1,0)&&IF((C2-C)*100/C2<(10-0.01*100/C2),1,0) OR IF((O-C)*100/O>=5,1,0)&&IF((C2-C)*100/C2<(10-0.01*100/C2),1,0); STICKLINE(大阴线,OPEN,CLOSE,-1,0),COLORGREEN;STICKLINE(大阴线,H,L,0,1),COLORGREEN;TY:=C;AA1:=REF(TY,10)=HHV(TY,2*10+1); BB1:=FILTER(AA1,10);C1:=BACKSET(BB1,10+1); HD:=FILTER(C1,10);AA2:=REF(TY,10)=LLV(TY,2*10+1); B2:=FILTER(AA2,10);CC2:=BACKSET(B2,10+1); LD:=FILTER(CC2,10);前期高位:REF(H,BARSLAST(HD)),COLOR00FF00,CIRCLEDOT;前期低位:REF(L,BARSLAST(LD)),COLORFF00FF,CIRCLEDOT;{黄金柱}JJ:=(3*C+H+L+O)/6;VAR1:=(8*JJ+7*REF(JJ,1)+6*REF(JJ,2)+5*REF(JJ,3)+4*REF(JJ,4)+3*REF(JJ ,5)+2*REF(JJ,6)+REF(JJ,8))/36;TJ1:=VOL=HHV(VOL,10) AND VOL>2*REF(VOL,1) AND CLOSE>VAR1 AND C>REF(C,1);LJL:=FILTER(TJ1,5);TJ2:=IF(BARSLAST(LJL)=1 AND CLOSE>REF(HIGH,1),1,IF(BARSLAST(LJL)=2 AND CLOSE>REF(HIGH,2),1,IF(BARSLAST(LJL)=3 ANDCLOSE>REF(HIGH,3),1,0)));TP:=TJ2=1;STICKLINE(CLOSE,REF(LOW,BARSLAST(LJL)),REF(LOW,BARSLAST(LJL)),6,0), COLORYELLOW;TJ3:=IF(BARSLAST(LJL)=1 AND CLOSE>REF(LOW,1),1,IF(BARSLAST(LJL)=2 AND CLOSE>REF(LOW,2),1,IF(BARSLAST(LJL)=3 ANDCLOSE>REF(LOW,3),1,0)));STFZ:=TJ3=1;CL:=STFZ AND TP;TJCL:=FILTER(CL,3);DRAWTEXT(LJL,L*0.99,'黄'),COLORYELLOW;DRAWTEXT(LJL,L*0.95,'金'),COLORYELLOW;DRAWTEXT(LJL,L*0.90,'柱'),COLORYELLOW;{涨停跟踪}ZT:=C/REF(C,1)>1.097;XH:=FILTER(ZT,13);BH:=BARSLAST(ZT);CZ:=REF(H,BH)-REF(L,BH);STICKLINE(C,(REF(L,BH)+CZ*0.5),(REF(L,BH)+CZ*0.5),7,0),COLORRED; STICKLINE(C,REF(L,BH),REF(L,BH),7,0),COLORBLUE;DRAWTEXT(ZT,L*0.98,'涨停'),COLORF00FF0;VARZT:=BARSLAST(C/REF(C,1)>1.097);STICKLINE(VARZT=2,L*0.97,L*0.98,8,0),COLOR0000FF;DRAWTEXT(VARZT=2,L*0.95,'3天'),COLORYELLOW;STICKLINE(VARZT=4,H*1.03,H*1.02,8,0),COLOR9966FF;DRAWTEXT(VARZT=4,H*1.06,'5天'),COLORYELLOW;STICKLINE(VARZT=7,L*0.97,L*0.98,8,0),COLOR00FFFF;DRAWTEXT(VARZT=7,L*0.95,'8天'),COLORYELLOW;STICKLINE(VARZT=12,H*1.03,H*1.02,8,0),COLORFF33FF;DRAWTEXT(VARZT=12,H*1.06,'13天'),COLORYELLOW;STICKLINE(VARZT=20,L*0.97,L*0.98,8,0),COLOR0066FF;DRAWTEXT(VARZT=20,L*0.95,'21天'),COLORYELLOW;STICKLINE(VARZT=33,H*1.03,H*1.02,8,0),COLOR9932CD;DRAWTEXT(VARZT=33,H*1.06,'34天'),COLORYELLOW; STICKLINE(VARZT=54,L*0.97,L*0.98,8,0),COLOR006600; DRAWTEXT(VARZT=54,L*0.95,'55天'),COLORYELLOW; STICKLINE(VARZT=88,H*1.03,H*1.02,8,0),COLOR00FF00; DRAWTEXT(VARZT=88,H*1.06,'89天'),COLORYELLOW; STICKLINE(VARZT=143,L*0.97,L*0.98,8,0),COLORCCFFFF; DRAWTEXT(VARZT=143,L*0.95,'144天'),COLORYELLOW; STICKLINE(VARZT=232 ,H*1.03,H*1.02,8,0),COLORFF0033; DRAWTEXT(VARZT=232,H*1.06,'233天'),COLORYELLOW; STICKLINE(VARZT=376,L*0.97,L*0.98,8,0),COLORFF9966; DRAWTEXT(VARZT=376,L*0.95,'377天'),COLORYELLOW;。

通达信牛暴涨主图指标公式通达信指标公式源码

通达信牛暴涨主图指标公式通达信指标公式源码

通达信⽜暴涨主图指标公式通达信指标公式源码通达信⽜暴涨主图指标公式Z1:=STRCAT(HYBLOCK,' ');Z2:=STRCAT(Z1,DYBLOCK);Z3:=STRCAT(Z2,' ');DRAWTEXT_FIX(ISLASTBAR,0,0,0,STRCAT(Z3,GNBLOCK)),COLORRED;ZK1:(XMA(XMA(H,25),25)-XMA(XMA(L,25),25))*1+XMA(XMA(H,25),25),DOTL INE,COLORBLUE;ZD1:XMA(XMA(L,25),25)-(XMA(XMA(H,25),25)-XMA(XMA(L,25),25))*1,LINET HICK2,COLORRED;ZD2:EMA(ZD1,25),LINETHICK2;DRAWBAND(ZD1,RGB(55,0,0),ZD2,RGB(0,91,0));DRAWKLINE(H,O,L,C);STICKLINE(ZD1>LOW ANDZD1MIN(C,O) ANDZD1STICKLINE(ZD1>HIGH,OPEN,CLOSE,2,0),COLORYELLOW;STICKLINE(ZD1>HIGH,HIGH,LOW,0,0),COLORYELLOW;VAR23:=100*XMA(XMA((C-REF(C,1)),6),6)/XMA(XMA(ABS((C-REF(C,1))),6),6 );回调买:=LLV(VAR23,2)=LLV(VAR23,7) AND COUNT(VAR23<0,2) AND CROSS(VAR23,MA(VAR23,2)); XG:=ZD1>HIGH AND 回调买AND L<=ZD1;DRAWTEXT(XG,L,'▲买⼊'),COLORRED;JJ:=(HIGH+LOW+CLOSE)/3;QJ0:=VOL/IF(HIGH=LOW,4,HIGH-LOW);QJ1:=IF(CAPITAL=0,QJ0*(JJ-MIN(CLOSE,OPEN)),QJ0*IF(HIGH=LOW,1,(MIN (OPEN,CLOSE)-LOW)));QJ2:=IF(CAPITAL=0,QJ0*(MIN(OPEN,CLOSE)-LOW),QJ0*IF(HIGH=LOW,1,(JJ -MIN(CLOSE,OPEN))));QJ3:=IF(CAPITAL=0,QJ0*(HIGH-MAX(OPEN,CLOSE)),QJ0*IF(HIGH=LOW,1,( HIGH-MAX(OPEN,CLOSE)))); QJ4:=IF(CAPITAL=0,QJ0*(MAX(CLOSE,OPEN)-JJ),QJ0*IF(HIGH=LOW,1,(MAX (CLOSE,OPEN)-JJ))); DDX:=((QJ1+QJ2)-(QJ3+QJ4))/IF(CAPITAL=0,10000,10000),COLOR00AAAA, LINETHICK;V2:=SMA(IF(C>=REF(C,1),DDX,-DDX/100),2,1);V5:=SMA(V2*120/FROMOPEN*5,2,1);V10:=SMA(V5,5,1);V20:=SMA(V10,5,1);DY:=CURRBARSCOUNT=1 AND CDY2:=REF(V2,1)-DY;XG2:=C>O AND DY2<0.02 AND MA(C,5)>MA(C,60) AND C/REF(C,1)>=1.02 AND H{DRAWTEXT(XG2,L,'▲抓⽜'),COLORYELLOW;}DRAWTEXT(XG2 AND L超B:=L2_AMO(0,2)/10000.0;⼤B:=L2_AMO(1,2)/10000.0;中B:=L2_AMO(2,2)/10000.0;⼩B:=L2_AMO(3,2)/10000.0;超S:=-L2_AMO(0,3)/10000.0;⼤S:=-L2_AMO(1,3)/10000.0;中S:=-L2_AMO(2,3)/10000.0;⼩S:=-L2_AMO(3,3)/10000.0;TESTSKIP(NOT(超B OR ⼤B OR 中B OR ⼩B OR 超S OR ⼤S OR 中S OR ⼩S)!=0);净流⼊:=(超B+⼤B+中B+⼩B)+(超S+⼤S+中S+⼩S);⼤宗净流⼊:=(超B+⼤B)+(超S+⼤S);超⼤单:=(超B)+(超S);⼤单:=(⼤B)+(⼤S);中单:=(中B)+(中S);⼩单:=(⼩B)+(⼩S);⼤宗进:=(超B)+(⼤B);⼤宗出:=(超S)+(⼤S);⾮⼤宗进:=(中B)+(⼩B);⾮⼤宗出:=(中S)+(⼩S);资⾦流向:=(超B+⼤B+中B+⼩B)+(超S+⼤S+中S+⼩S);近5⽇流向:=SUM(资⾦流向,5);近10⽇流向:=SUM(资⾦流向,10);主⼒资⾦线:=(L2_AMO(0,0)+L2_AMO(1,0)-L2_AMO(0,1)-L2_AMO(1,1))/100.0,LINETHI CK2;主⼒买⼒度:=LARGEINTRDVOL*100/VOL;主⼒卖⼒度:=LARGEOUTTRDVOL*100/VOL;AAB:=CONST(MAX(ABS(超⼤单),MAX(ABS(⼤单),MAX(ABS(中单),ABS(⼩单))))),NODRAW;DRAWRECTREL(5,CONST(830-(ABS(超⼤单)*500/AAB))/2,35,460,IF(CONST(超⼤单)>0,RGB(255,0,255),RGB(0,255,255)));DRAWRECTREL(40,CONST(830-(ABS(⼤单)*500/AAB))/2,70,460,IF(CONST(⼤单)>0,RGB(255,0,255),RGB(0,255,255))); DRAWRECTREL(75,CONST(830-(ABS(中单)*500/AAB))/2,105,460,IF(CONST(中单)>0,RGB(255,0,255),RGB(0,255,255)));DRAWRECTREL(110,CONST(830-(ABS(⼩单)*500/AAB))/2,140,460,IF(CONST(⼩单)>0,RGB(255,0,255),RGB(0,255,255)));DRAWTEXT_FIX(CURRBARSCOUNT=1,0.007,0.46,0,'超户⼤户中户散户'),COLORWHITE;DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.007,0.4,0,INTPART(超⼤单)),COLORWHITE;DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.042,0.4,0,INTPART(⼤单)),COLORWHITE;DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.076,0.4,0,INTPART(中单)),COLORWHITE;DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.112,0.4,0,INTPART(⼩单)),COLORWHITE;TYX3:=MA(REF(HHV((C+L+O+H)/4,30),1),3);筹码突破:=C>TYX3AND(C-REF(C,1))*100/REF(C,1)>=(10-0.01*100/REF(C,1)),COLORRED;A111:=COST(85);A222:=COST(15);A333:=A111-A222;A444:=(A111+A222)/2;单峰密集:=A333/A444*100<30,LINETHICK0;{A5:=A3/A4*100<30;}B1:=HHV(HIGH,250);B2:=LLV(LOW,250);B3:=B1-B2;B4:=(A444-B2);低位:=A444<(B3*04+B2),LINETHICK0;低位单峰密集:=单峰密集AND 低位;B5:=C/REF(C,1)>1.04; {AND V/REF(V,1)>2;{ AND H=C;}主⼒持仓%:=EMA(100*(CLOSE-LLV(LOW,30))/(HHV(HIGH,30)-LLV(LOW,30)),3);主⼒持仓⼤于75%:=主⼒持仓%>=75 {AND 主⼒持仓%<=91} AND C>0 AND CLOSE>OPEN AND C=H;敢死吗:=主⼒持仓⼤于75% AND 低位单峰密集AND B4 ANDWINNER(C)>=0.91 AND B5,COLORGREEN,LINETHICK3;{DRAWTEXT(FILTER(敢死吗=1,5),L,'----敢死吗'),COLORGREEN;} DRAWICON(FILTER(敢死吗=1,5),L*0.995,25);DIF1:=EMA(DCLOSE,12)-EMA(DCLOSE,26);DEA1:=EMA(DIF1,9);AAA1:=(DIF1-DEA1)*2*60;AAA上:=IF(AAA1>REF(AAA1,1),AAA1,DRAWNULL);AAA下:=IF(AAA1买:=13;⼊:=AAA1-REF(AAA1,1);正⼤:=CROSS(⼊,买);DIF2:=EMA(DCLOSE,10)-EMA(DCLOSE,72);DEA2:=EMA(DIF2,17);AAA:=(DIF2-DEA2)*2*60;⼊2:=AAA-REF(AAA,1);⽜股:=CROSS(⼊2,13);正⼤⽜股:=正⼤AND ⽜股;DRAWICON(正⼤⽜股,L*0.99,1);VAR1:=(CLOSE-MA(CLOSE,7))/MA(CLOSE,7)*100;VAR2:=(CLOSE-LLV(LOW,21))/(HHV(HIGH,21)-LLV(LOW,21))*100; VAR3:=SMA(VAR2,3,1);天:=100+(-ABS(VAR1)),COLORRED;下:=SMA(VAR3,2,1);⽆:=ABS(VAR1),COLORGREEN;敌:=50,COLORFFAA00,LINETHICK3;LC:=REF(CLOSE,1);操作线:=SMA(MAX(CLOSE-LC,0),2,1)/SMA(ABS(CLOSE-LC),2,1)*100; 卖:=CROSS(90,操作线); DRAWICON(卖,H*1.01,8);绝底线:=5;买阴线1:操作线<5 AND ZD1>ZD2 AND LDRAWICON(买阴线1,L*0.98,7);买阴线2:操作线<5 AND ZD1DRAWICON(买阴线2,L*0.995,7);DRAWTEXT_FIX(1,0.20,0.88,0,HYBLOCK),COLORGREEN;DRAWTEXT_FIX(1,0.20,0.94,0,EXTERNSTR(0,3))COLORFF88FF;。

通达信经典分时主图 源码指标公式

通达信经典分时主图 源码指标公式

DRAWGBK(O>=0,RGB(60,35,0),RGB(0,60,60),0,'背景图',0),LINETHICK2;{========================额外==========================} Z1:=STRCAT(DYBLOCK,' ');Z2:=STRCAT(Z1,HYBLOCK);Z3:=STRCAT(Z2,' ');Z4:=STRCAT(Z3,GNBLOCK);Z5:=STRCAT(Z4,' ');Z6:=STRCAT(Z5,FGBLOCK);DRAWTEXT_FIX(ISLASTBAR,0.01,0.012,0,STRCAT(Z6,ZHBLOCK)),COLORCYAN;DRAWTEXT_FIX(ISLASTBAR,0,0.14,0,STRCAT('概念: ',GNBLOCK)),COLORWHITE;A1:=(VOL/CLOSE)/3;A2:=SUM((IF(((A1>40) AND (CLOSE>(REF(CLOSE,1)))),A1,0)),0);A3:=SUM((IF(((A1>40) AND (CLOSE<(REF(CLOSE,1)))),A1,0)),0);A4:=SUM((IF(((A1<40) AND (CLOSE>(REF(CLOSE,1)))),A1,0)),0);突破:=REF(EMA(C,14),1);A1X:=(EMA(C,10)-突破)/突破*100;多方:=IF(A1X>=0,REF(EMA(C,10),BARSLAST(CROSS(A1X,0))+1),DRAWNULL);空方:=IF(A1X<0,REF(EMA(C,10),BARSLAST(CROSS(0,A1X))+1),DRAWNULL); STICKLINE(A1X>=0,多方,突破,0,0),COLOR000099;STICKLINE(A1X<0,空方,突破,0,0),COLOR00CC66;最新:CLOSE,LINETHICK1,COLORWHITE;AA:=SUM(AMOUNT,BARSCOUNT(C))/SUM(VOL*100,BARSCOUNT(C));BB:=BETWEEN(C/AA,C+H,C-H);DRAWTEXT( ISLASTBAR AND 最新>REF(最新,1),最新,STRCAT(' 涨▲',CON2STR(最新,2))),COLORMAGENTA;DRAWTEXT( ISLASTBAR AND 最新<REF(最新,1),最新,STRCAT(' 跌▼',CON2STR(最新,2))),COLOR00FF00;DRAWTEXT_FIX(1,0.880,1-0.97,0,DYBLOCK),COLORWHITE;DRAWTEXT_FIX(1,0.940,1-0.97,0,HYBLOCK),COLORYELLOW;均价:SUM(C*V,240)/SUM(V,240),COLORYELLOW,LINETHICK1;DXJP:=(CLOSE-LLV(LOW,34))/(HHV(HIGH,21)-LLV(LOW,34))*100;FSZX:=(EMA(DXJP,3)-50)*2,COLORGRAY;BGTYU:=IF(DATE<=1150530,1,0);GHYJKU:=BETWEEN((DCLOSE*BGTYU)/(SUM(AMOUNT,BARSCOUNT((DCLOSE*BGTYU)) )/SUM(VOL*100,BARSCOUNT((DCLOSE*BGTYU)))),1.05,0.95);VBNH:=IF(GHYJKU=0,MA((DCLOSE*BGTYU),BARSCOUNT((DCLOSE*BGTYU))),(SUM(AMOUNT,BARSCOUNT((DCLOSE*BGTYU)))/SUM(VOL*100,BARSCOUNT((DCLOSE*BGTYU))) ));DRAWICON(FSZX<=-95,C,38);DRAWTEXT(CROSS(EXPMA((DCLOSE/VBNH),20),1.04),C,'板'),COLORCYAN; DRAWTEXT(CROSS(EXPMA((DCLOSE/VBNH),20),1.02),C,'追'),COLORYELLOW;H1:=MAX(DYNAINFO(3),DYNAINFO(5));L1:=MIN(DYNAINFO(3),DYNAINFO(6));P1:=H1-L1;阻力:=L1+P1*7/8,COLORGREEN;支撑:=L1+P1*0.5/8,COLORMAGENTA;DRAWICON(LONGCROSS(支撑,C,2),C,5);AYGB1:=(DVOL/C)/2,NODRAW;AYGB2:=SUM(IF(AYGB1>100 AND CLOSE>REF(CLOSE,1),AYGB1,0),0);AYGB3:=SUM(IF(AYGB1>100 AND CLOSE<REF(CLOSE,1),AYGB1,0),0);AYGB4:=SUM(IF(AYGB1<100 AND CLOSE>REF(CLOSE,1),AYGB1,0),0);AYGB5:=SUM(IF(AYGB1<100 AND CLOSE<REF(CLOSE,1),AYGB1,0),0);AYGB6:=AYGB2+AYGB3+AYGB4+AYGB5;机买:=(AYGB2/AYGB6)*100-100,LINETHICK1,COLORRED;机卖:=(AYGB3/AYGB6)*100-100,LINETHICK1,COLORGREEN;主力差:=机买-机卖;LQH:=主力差>0 AND REF(主力差,1)<=0;DRAWICON(LQH,C,25);JJXX:=IF(BETWEEN(C/(SUM(AMOUNT,0)/SUM(VOL*100,0)),1.05,0.95)=0,MA(C,0),(SUM( AMOUNT,0)/SUM(VOL*100,0))),COLORYELLOW;JJXXH:=(JJXX*1.007 ),COLORFF6600;FFLL:=SUM(VOL,6)>REF(MA(VOL,30),1)*10;HHPP:=((HHV(CLOSE,BARSCOUNT(CLOSE))-LLV(CLOSE,BARSCOUNT(CLOSE)))/CLOSE)< 1;HHZZ:=HHPP AND FFLL AND (C>JJXXH);TTPP2:=FILTER(HHZZ,100);DRAWICON(TTPP2,C,26);ZS:=DYNAINFO(3);KP:=DYNAINFO(4);ZX:=DYNAINFO(7);ZG:=DYNAINFO(5);ZD:=DYNAINFO(6);分时均价线:SUM(C*V,240)/SUM(V,240),COLORYELLOW;RC:=DYNAINFO( 3);量比超2.5:=IF(DYNAINFO(17)>2.5,RC-0.15,DRAWNULL),COLORFF9933;量比超5:=IF(DYNAINFO(17)>5,RC-0.15,DRAWNULL),COLORBA75FF;DRAWBAND(量比超2.5,RGB(51,153,255),量比超2.5+0.015,RGB(51,153,255)); DRAWBAND(量比超5,RGB(255,118,188),量比超5+0.015,RGB(255,118,188));{首次起爆}TT:=BARSCOUNT(C);{取得有效收盘价}均价黄:SUM(C*V,TT)/SUM(V,TT),LINETHICK1,COLOR00FFE1;{分时均线的取值}量两步:=MA(V,5)>REF(MA(V,5),1) AND REF(MA(V,5),1)>REF(MA(V,5),2);价两步:= C>=REF(C,1) AND REF(C,1)>REF(C,2);价上岗量破5:=C>均价黄AND V>MA(V,5);量起爆:=V>=REF(V,1)*2 ;价创新高:=C>=HHV(C,0);量创新高:=V>=HHV(V,0);对昨日涨幅:=C/DYNAINFO(3)<=1.02;{涨幅控制2个点以内}每日一点:=量两步AND 价两步AND 价上岗量破5 AND 量起爆AND 价创新高AND 量创新高AND 对昨日涨幅;{计算收益、已爆分钟}VC:=BARSSINCE(每日一点)+1;首次起爆价:REF(C,VC-1),NODRAW;今天收益:(DYNAINFO(7)-首次起爆价)/首次起爆价*100,NODRAW;起爆时间:REF(TIME/10000,VC),NODRAW;已爆分钟:VC-1,NODRAW;首次起爆量:=REF(VOL,VC-1);DRAWICON(已爆分钟>=2,RC-0.1,11);{出现金手指,至少已经确认2分钟了};R1:=MA(C,13);R2:=SMA(R1,5,2);DRAWBAND(R1,RGB(255,0,125),R2,RGB(0,111,255));C,LINETHICK2,COLORDDDDDD;{涨停}地:=DYNAINFO(11)+(DYNAINFO(11)*0.021);涨停:IF(DYNAINFO(7)>地,1,0),NODRAW,COLOR0088FF;涨:=IF(涨停=1,C+0.0075,DRAWNULL),COLOR8000FF,LINETHICK2;DRAWBAND(涨,RGB(255,211,0),C-0.0075,RGB(255,125,0));时间:=TIME=100000;N:=BARSLAST(时间);常数:=CONST(IF(N=0,C,REF(C,N))),COLORGREEN,DOTLINE;CS1:=CONST(IF(N,HHV(H,0),REF(HHV(H,0),N)));CS2:=CONST(IF(N,LLV(L,0),REF(LLV(L,0),N)));STICKLINE(时间=1,CS1,CS2,1.2,0),COLOR008888;{涨停2}AAZ:=BARSLAST(TIME=103000);CC:=REF(HHV(C,0),AAZ+1);VV:=REF(HHV(V,0),AAZ+1);ZF:=CC/DYNAINFO(3)<1.05;涨停2:=CROSS(C,CC) AND V>VV AND ZF,COLOR0000FF; DRAWICON(涨停2,RC-0.06,13);A:=O>C AND C>REF(C,1) AND O/REF(C,1)>1.03; DRAWTEXT(ABS(A)>0,L, '假阴'),COLORYELLOW;均价5:AMOUNT/VOL/100,NODRAW;假阴0:=O>C AND 均价5>REF(C,1);DRAWTEXT(假阴0,L-0.2,'假阴真阳'),COLORE8E8E8; STICKLINE(假阴0,O,C,1,0),COLORRED;时间N:=TIME=100000;NN:=BARSLAST(时间N),COLOR808080;常数N:CONST(IF(NN=0,C,REF(C,N))),COLOR004848,DOTLINE;。

通达信指标公式源码 分时主图十点画大十字+三日K线

通达信指标公式源码 分时主图十点画大十字+三日K线

源码:O1:REF(O,1);C1:REF(C,1);H1:REF(H,1);L1:REF(L,1);O2:REF(O,2);C2:REF(C,2);H2:REF(H,2);L2:REF(L,2);O3:REF(O,3);C3:REF(C,3);H3:REF(H,3);L3:REF(L,3);二、分时主图10点画大十字+三日K线,名称随意起。

源码:O1:="SS.O1#DAY";C1:="SS.C1#DAY";H1:="SS.H1#DAY";L1:="SS.L1#DAY";O2:="SS.O2#DAY";C2:="SS.C2#DAY";H2:="SS.H2#DAY";L2:="SS.L2#DAY";O3:="SS.O3#DAY";C3:="SS.C3#DAY";H3:="SS.H3#DAY";L3:="SS.L3#DAY";GGJ:=CONST(IF(BARSLAST(TIME=93100),HHV(H,0),REF(HHV(H,0),BARSLAS T(TIME=93100))));DDJ:=CONST(IF(BARSLAST(TIME=93100),LLV(H,0),REF(LLV(H,0),BARSLAST( TIME=93100))));E1:=IF(BETWEEN(TIME,94900,95700),O1,DRAWNULL);E2:=IF(BETWEEN(TIME,94900,95700),C1,DRAWNULL);E12:=IF(BETWEEN(TIME,94000,94800),O2,DRAWNULL);E22:=IF(BETWEEN(TIME,94000,94800),C2,DRAWNULL);E13:=IF(BETWEEN(TIME,93100,93900),O3,DRAWNULL);E23:=IF(BETWEEN(TIME,93100,93900),C3,DRAWNULL);时间:=TIME=100000;N:=BARSLAST(时间);CS1:=CONST(IF(N,HHV(H,0),REF(HHV(H,0),N)));CS2:=CONST(IF(N,LLV(L,0),REF(LLV(L,0),N)));三高:=IF(BETWEEN(TIME,93100,100000),MAX(H1,MAX(H2,H3)),DRAWNULL); 三低:=IF(BETWEEN(TIME,93100,100000),MIN(L1,MIN(L2,L3)),DRAWNULL);三日高:=IF(BETWEEN(TIME,95700,100000),MAX(H1,MAX(H2,H3)),DRAWNULL);三日低:=IF(BETWEEN(TIME,95700,100000),MIN(L1,MIN(L2,L3)),DRAWNULL); 三日高1:=IF(BETWEEN(TIME,94900,93100),MAX(H1,MAX(H2,H3)),DRAWNULL);三日低1:=IF(BETWEEN(TIME,954900,93100),MIN(L1,MIN(L2,L3)),DRAWNULL);三日高2:=IF(BETWEEN(TIME,94000,93100),MAX(H1,MAX(H2,H3)),DRAWNULL);三日低2:=IF(BETWEEN(TIME,94000,93100),MIN(L1,MIN(L2,L3)),DRAWNULL); DRAWBAND(三日高,RGB(0,0,0),三日低,RGB(0,0,0));STICKLINE(TIME=95300 AND C1>O1,H1,L1,1,0),COLOR0000CC; STICKLINE(TIME=95300 AND C1<O1,H1,L1,1,0),COLORFFFF54; STICKLINE(TIME=95300 AND C1=O1,H1,L1,1,0),COLORWHITE; DRAWBAND(IF(C1>O1,E2,DRAWNULL),RGB(204,0,0),E1,RGB(204,0,0)); DRAWBAND(IF(C1<O1,E2,DRAWNULL),RGB(84,255,255),E1,RGB(84,255,255) );DRAWBAND(IF(C1=O1,E2,DRAWNULL),RGB(255,255,255),E1,RGB(255,255,2 55));DRAWBAND(三日高1,RGB(0,0,0),三日低1,RGB(0,0,0));STICKLINE(TIME=94400 AND C2>O2,H2,L2,1,0),COLOR0000CC; STICKLINE(TIME=94400 AND C2<O2,H2,L2,1,0),COLORFFFF54; STICKLINE(TIME=94400 AND C2=O2,H2,L2,1,0),COLORWHITE;DRAWBAND(IF(C2>O2,E22,DRAWNULL),RGB(204,0,0),E12,RGB(204,0,0)); DRAWBAND(IF(C2<O2,E22,DRAWNULL),RGB(84,255,255),E12,RGB(84,255,2 55));DRAWBAND(IF(C2=O2,E22,DRAWNULL),RGB(255,255,255),E12,RGB(255,255 ,255));DRAWBAND(三日高2,RGB(0,0,0),三日低2,RGB(0,0,0));STICKLINE(TIME=93500 AND C3>O3,H3,L3,1,0),COLOR0000CC; STICKLINE(TIME=93500 AND C3<O3,H3,L3,1,0),COLORFFFF54; STICKLINE(TIME=93500 AND C3=O3,H3,L3,1,0),COLORWHITE; DRAWBAND(IF(C3>O3,E23,DRAWNULL),RGB(204,0,0),E13,RGB(204,0,0)); DRAWBAND(IF(C3<O3,E23,DRAWNULL),RGB(84,255,255),E13,RGB(84,255,2 55));DRAWBAND(IF(C3=O3,E23,DRAWNULL),RGB(255,255,255),E13,RGB(255,255 ,255));{ m}STICKLINE(时间=1,三日高,三日低,-1,-1),COLOR0000CC;IF(BETWEEN(TIME,93100,94000) ANDBETWEEN(C,C1,O1),C,DRAWNULL),COLORWHITE;STICKLINE(时间=1,CS1,CS2,-1,-1),COLORGREEN;均价:SUM(V*C,0)/SUM(V,0),COLORYELLOW;CONST(IF(N,LLV(L,0),REF(LLV(L,0),N))),COLOR888888;CONST(IF(N,HHV(H,0),REF(HHV(H,0),N))),COLOR888888;CONST(IF(时间,HHV(H,0),REF(HHV(H,0),N))),COLORRED,DOTLINE; CONST(IF(时间,LLV(L,0),REF(LLV(L,0),N))),COLORLIBLUE,DOTLINE;常数:CONST(IF(N=0,C,REF(C,N))),COLORGREEN,DOTLINE; DRAWNUMBER(TIME=93500,常数,常数),COLORMAGENTA; DRAWNUMBER(时间,GGJ*0.999,GGJ),COLORMAGENTA; DRAWNUMBER(时间,DDJ*1.001,DDJ),COLORMAGENTA;IF(BETWEEN(C,三高,三低),C,DRAWNULL),COLORWHITE;IF(C=GGJ,C,DRAWNULL),COLORWHITE;。

很牛的主图时间之窗通达信指标公式源码

很牛的主图时间之窗通达信指标公式源码

很牛的主图(包括跟庄.支撑.压力.买卖点等等)直接上图!家人再也不担心你炒股了!DRAWGBK(C>0,RGB(0,150,150),RGB(0,00,100),0,' ',0),LINETHICK2;M80:MA(C,80),LINETHICK0;M200:MA(C,200),LINETHICK0;DRAWBAND(M200,RGB(40,100,40),M80,RGB(100,100,0)),LINETHICK0; DRAWKLINE(H,O,L,C);MA03:MA(C,3),COLORYELLOW,DOTLINE,LINETHICK0;IF(MA03>=REF(MA03,1),MA03,DRAWNULL),COLOR0066FF,LINETHICK0;IF(MA03< REF(MA03,1),MA03,DRAWNULL),,COLORGREEN,LINETHICK0;X:=(3*C+L+O+H)/6;多空线:(20*X+19*REF(X,1)+18*REF(X,2)+17*REF(X,3)+16*REF(X,4)+15*REF(X,5)+14*REF (X,6)+13*REF(X,7)+12*REF(X,8)+11*REF(X,9)+10*REF(X,10)+9*REF(X,11)+8*REF(X,12) +7*REF(X,13)+6*REF(X,14)+5*REF(X,15)+4*REF(X,16)+3*REF(X,17)+2*REF(X,18)+ REF(X,20))/210,COLORGREEN,LINETHICK2;IF(多空线>=REF(多空线,1),多空线,DRAWNULL),COLORRED,LINETHICK3;IF(多空线< REF(多空线,1),多空线,DRAWNULL),,COLORGREEN,LINETHICK3;牛皮熊:DRAWICON(CROSS(MA03,多空线) ANDCLOSE/REF(CLOSE,1)>1.03,LOW*0.96,25);DRAWTEXT(FILTER(牛皮熊,8),多空线-0.05,'↖跟庄买进'),COLORGREEN; DRAWTEXT(CROSS(MA03,多空线) AND MA03>0,多空线-0.23,'★←'),COLORYELLOW; 花:=SLOPE(EMA(C,3),3);神:=SLOPE(EMA(C,7),7);DRAWICON(CROSS(花,神) AND CLOSE/REF(CLOSE,1)>1.03,LOW*0.96,25); DRAWTEXT(CROSS(花,神) AND CLOSE/REF(CLOSE,1)>1.03,LOW*0.96,'买'),COLORWHITE;花2:=EMA(SLOPE(1,1)+C,3),COLORRED;神2:=EMA(SLOPE(1,1)+C,7),COLORBLUE;A02:=3*EMA((C-LLV(L,30))/(HHV(H,30)-LLV(L,30))*100,5)-2*EMA((C-LLV(L,30))/(HHV( H,30)-LLV(L,30))*100,5);A4:=(HHV(H,34)-C)/(HHV(H,34)-LLV(L,34))*100;A5:=EMA(CLOSE,12)-EMA(CLOSE,26);A6:=EMA(A5,9);A7:=(A5<-0.1 AND A5>A6);财神:IF(A7,LLV(L,21),DRAWNULL)COLORRED,CIRCLEDOT;DRAWTEXT_FIX(1,0.07,0,0,HYBLOCK)COLOR0080FF;DRAWTEXT_FIX(1,0.01,0.08,0,'主题投资:')COLOR0000FF;DRAWTEXT_FIX(1,0.09,0.08,0,EXTERNSTR(0,1))COLOR0000FF;窗口显示:=C>REF(C,1)*1.095 AND C=H;T:=BARSLAST(窗口显示),LINETHICK0;涨停价:REF(C,T)NODRAW,LINETHICK0;涨停日期:REF(DATE-1000000,T)NODRAW,LINETHICK0;STICKLINE(L>REF(H,1),L,REF(H,1),20,1001), COLORYELLOW ,LINETHICK0; STICKLINE(REF(L,1)>H,REF(L,1),H,20,1001), COLORGREEN ,LINETHICK0;TJ01:=C<O AND REFX(C<O,1) AND REFX(C>O,2);DRAWLINE(TJ01,REFX(LLV(L,2),1),REF(TJ01,1),REF(REFX(LLV(L,2),1),1),1)COLORYELLO W,LINETHICK0;DRAWLINE(TJ01,REFX(HHV(C,2),1),REF(TJ01,1),REF(REFX(HHV(C,2),1),1),1)COLORYEL LOW,LINETHICK0;{波峰}TY:=H;A1:=REF(TY,10)=HHV(TY,2*10+1); B1:=FILTER(A1,10); C1:=BACKSET(B1,10+1); HD:=FILTER(C1,10);A2:=REF(TY,10)=LLV(TY,2*10+1); B2:=FILTER(A2,10); C002:=BACKSET(B2,10+1); LD:=FILTER(C002,10);波峰:REF(H,BARSLAST(HD)),COLOR00808F,POINTDOT,LINETHICK4;STICKLINE(H,波峰,波峰,8,0),COLOR00808F,LINETHICK4;BDGD:=C=HHV(C,13);GDSJ:=BARSLAST(FILTER(CROSS(0.8,BDGD),2))+1;高点:REF(C,GDSJ),COLORGREEN,LINETHICK4,POINTDOT;突破:CROSS(C,REF(高点,1)),COLOR00FFFF,POINTDOT,LINETHICK0;STICKLINE(GDSJ<=6,高点,高点,8,0),COLORGREEN,LINETHICK2;BDDD:=C=LLV(C,13);DDSJ:=BARSLAST(FILTER(CROSS(0.8,BDDD),2))+1;低点:REF(C,DDSJ),COLOR0055FF,POINTDOT,LINETHICK4;STICKLINE(DDSJ<=6,低点,低点,8,0),COLOR0055FF,LINETHICK4;AAA:=(REF(CLOSE,1)+REF(CLOSE,2)+OPEN)/3;前高:DRAWLINE(CURRBARSCOUNT=3,H,REF(CURRBARSCOUNT=3,1),REF(H,1),1),LINETHI CK2;昨收:DRAWLINE(CURRBARSCOUNT=2,C,REF(CURRBARSCOUNT=2,1),REF(C,1),1),LINETHI CK2;压力线:DRAWLINE(HIGH>=HHV(HIGH,10),HIGH,LOW<=LLV(LOW,3),HHV(HIGH,3),1),COLO RYELLOW,LINETHICK0;DRAWTEXT(压力线,L-0.2,'压力↙'),COLORYELLOW,LINETHICK0;MA010:=MA(CLOSE,10),COLORYELLOW,LINETHICK0;MA54:=MA(CLOSE,54),COLORFFCCCC,LINETHICK0;PL1:=(((CLOSE - MA54) / MA54) < 0.1);PL2:=(((CLOSE - MA010) / MA010) < 0.3);偏离率:=(((PL1 = 1) AND (PL2 = 1)) * 0.2);平台突破:=((((偏离率= 0) AND (REF(偏离率,1) = 0.2)) AND (REF((COUNT((偏离率= 0.2),10) = 10),1) = 1)) * 1);DRAWTEXT(平台突破,L,'=================='),COLORWHITE; DRAWTEXT(平台突破,L-0.05,'平台突破'),COLORGREEN;三日最低:=EMA((REF(L,4)+REF(L,3)+REF(L,2))/3,3);三日最高:=EMA((REF(H,4)+REF(H,3)+REF(H,2))/3,3);EXITLONG:CROSS(CROSS(三日最高,C),0.6);ENTERLONG:CROSS(CROSS(C,三日最低),0.5);STICKLINE(C/REF(C,1)>1.095,C,O,2,0),COLORYELLOW;涨停:=IF(REF(C,1)*1.095-C<0.01 ,1,0);STICKLINE(涨停,OPEN,CLOSE,2.5,0),COLORYELLOW;DRAWTEXT(涨停,L-0.1,'涨停'),COLORYELLOW;C3:=REF(C,1);跌停:=IF((C3-C)*100/C3>=(10-0.01*100/C3),1,0);STICKLINE(跌停,OPEN,CLOSE,2.5,0),COLORBLUE; DRAWTEXT(跌停,H+0.3,'跌停'),COLORBLUE;NN:=120;{跳空}STICKLINE(REF(L,1)>H,H,REF(L,1),5,0),COLORGRAY; STICKLINE(REF(H,1)<L,L,REF(H,1),5,0),COLORGRAY; {彩色K线}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((C-REF(C,1))*100/REF(C,1)>=(10-0.01*100/REF(C,1)),OPEN,CLOSE,1,0),CO LORYELLOW;STICKLINE((REF(C,1)-C)*100/REF(C,1)>=(10-0.01*100/REF(C,1)),OPEN,CLOSE,1,0),CO LORWHITE;{突破}STICKLINE(REF(COUNT(C<TYX3,5)=5,1) AND C>TYX3 AND C>O,C,O,1,0),COLOR00CCFF; STICKLINE(REF(COUNT(C<TYX3,5)=5,1) AND C>TYX3 ANDC>O,C,O,1,0),COLOR00CCFF;{红绿三角【副图】}A10304:=REF(HIGH,3)=HHV(HIGH,2*3+1);B10304:=FILTER(A10304,3);C10304:=BACKSET(B10304,3+1);D10304:=FILTER(C10304,3);{高点}A20304:=REF(LOW,3)=LLV(LOW,2*3+1);B20304:=FILTER(A20304,3);C20304:=BACKSET(B20304,3+1);D20304:=FILTER(C20304,3);{低点}E10304:=(REF(LLV(LOW,2*3),1)+REF(HHV(HIGH,2*3),1))/2;E20304:=(HIGH+LOW)/2;{高低点出现在同一K线上时可作取舍}H10304:=(D10304 AND NOT(D20304 AND E10304>=E20304)) OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;L10304:=(D20304 AND NOT(D10304 AND E10304=E20304));X10304:=REF(BARSLAST(H10304),1)+1;F10304:=BACKSET(H10304 ANDCOUNT(L10304,X10304)>0,LLVBARS(IF(L10304,LOW,10000),X10304));G10304:=F10304>REF(F10304,1);I10304:=BACKSET(G10304,2);LD0304:=I10304>REF(I10304,1);{过滤后低点}L20304:=LD0304 OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;X20304:=REF(BARSLAST(L20304),1)+1;F20304:=BACKSET(L20304 ANDCOUNT(H10304,X20304)>0,HHVBARS(IF(H10304,HIGH,0),X20304));G20304:=F20304>REF(F20304,1);I20304:=BACKSET(G20304,2);HD0304:=I20304>REF(I20304,1);{过滤后高点}UU0304:=BACKSET(BARSTATUS=2,BARSLAST(LD0304)+1);VV0304:=UU0304>REF(UU0304,1);UU20304:=BACKSET(BARSTATUS=2,BARSLAST(HD0304)+1);VV20304:=UU20304>REF(UU20304,1);{以下语句为三角形部分}底:REF(L,BARSLAST(VV0304)),COLORYELLOW,LINETHICK0;顶:REF(H,BARSLAST(VV20304)),COLORYELLOW,LINETHICK0;{下跌三角形:绿色三角形画完介入}STICKLINE(VV0304,顶,底,0,0),COLORGREEN,LINETHICK2;DRAWLINE(VV20304,H,VV0304,L,0),COLORGREEN,LINETHICK2;{斜}DRAWLINE(VV20304,H,VV0304,顶,0),COLORGREEN,LINETHICK2;{上涨三角形:红色三角形画完出局}STICKLINE(VV20304 ,顶,底,0,0),COLORBLUE,LINETHICK2;DRAWLINE(VV0304,L,VV20304,H,0),COLORBLUE,LINETHICK2;{斜}DRAWLINE(VV0304,L,VV20304,底,0),COLORBLUE,LINETHICK2;DRAWICON(C<O AND C>REF(C,1),H,6);{假阴真阳}均价:AMOUNT/VOL/100,NODRAW;假阴0:=O>C AND 均价>REF(C,1);DRAWTEXT(假阴0,L-0.2,'假阴↖'),COLORE8E8E8;STICKLINE(假阴0,O,C,1,0),COLORRED;VVOL:=IF(CURRBARSCOUNT=1 AND PERIOD=5,VOL*240/FROMOPEN,DRAWNULL);{模拟量}H_L:=0.1*CONST(HHV(VOL,240));长阴短柱:=C/REF(C,1)<=0.96 AND V<HHV(V,30)/1.9;DRAWTEXT(长阴短柱,V+1.6*0.098,'长阴短柱↙'),COLORLICYAN;MA05:=MA(C,5);MA5角度: ATAN((MA05/REF(MA05,1)-1)*100)*180/3.1416,NODRAW;T01:=CONST(LLVBARS(LOW,10));T1HIGH:=CONST(REF(HIGH,T01));MM:=CONST(CURRBARSCOUNT);T02:=CONST(BARSLAST(CURRBARSCOUNT>MM+T01 AND H>T1HIGH));T2HIGH:=CONST(REF(HIGH,T02));T03:=CONST(BARSLAST(CURRBARSCOUNT>MM+T02 AND HIGH>T2HIGH));T3HIGH:=CONST(REF(HIGH,T03));攻击线:DRAWLINE(CURRBARSCOUNT=T03+1, T3HIGH, ISLASTBAR,T3HIGH,1),LINETHICK3,COLOR8080FF;DRAWTEXT(ISLASTBAR, T3HIGH, '必杀攻击线')LINETHICK2,COLORCYAN;A6A:=REF(HIGH,6)=HHV(HIGH,2*6+1);B6A:=FILTER(A6A,6);C6A:=BACKSET(B6A,6+1);D6A:=FILTER(C6A,6);A7A:=REF(LOW,6)=LLV(LOW,2*6+1);B7A:=FILTER(A7A,6);C7A:=BACKSET(B7A,6+1);D7A:=FILTER(C7A,6);E6A:=(REF(LLV(LOW,2*6),1)+REF(HHV(HIGH,2*6),1))/2;E7A:=(HIGH+LOW)/2;H6A:=(D6A AND NOT(D7A AND E6A>=E7A)) OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;H7A:=D6A AND NOT(D7A AND E6A>=E7A);L6A:=D7A AND NOT(D6A AND E6A=E7A);X6A:=REF(BARSLAST(H6A),1)+1;F6A:=BACKSET(H6A AND COUNT(L6A,X6A)>0,LLVBARS(IF(L6A,LOW,10000),X6A)); G6A:=F6A>REF(F6A,1);I6A:=BACKSET(G6A,2);LD2A:=I6A>REF(I6A,1);L7A:=LD2A OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;X7A:=REF(BARSLAST(L7A),1)+1;F7A:=BACKSET(L7A AND COUNT(H7A,X7A)>0,HHVBARS(IF(H7A,HIGH,0),X7A));G7A:=F7A>REF(F7A,1);I7A:=BACKSET(G7A,2);HD2A:=I7A>REF(I7A,1);UU3A:=BACKSET(BARSTATUS=2,BARSLAST(LD2A)+1);VV3A:=UU3A>REF(UU3A,1);WW3A:=BACKSET(VV3A,REF(BARSLAST(LD2A),1)+2);XX3A:=WW3A>REF(WW3A,1);DRAWLINE(XX3A,L,VV3A,L,1),COLORCYAN,LINETHICK2;UU4A:=BACKSET(BARSTATUS=2,BARSLAST(HD2A)+1);VV4A:=UU4A>REF(UU4A,1);WW4A:=BACKSET(VV4A,REF(BARSLAST(HD2A),1)+2);XX4A:=WW4A>REF(WW4A,1);DRAWLINE(XX4A,H,VV4A,H,1),COLOR8000F0,LINETHICK2;HIGHN:=10;LOWN:=10;HIGHDISPLAY:=0;LOWDISPLAY:=0;ZGDISPLAY:=0;MADISPLAY:=0;AA:=REF(H,HIGHN)=HHV(H,2*HIGHN+1);QY:=BACKSET(AA,HIGHN+1);CC:=FILTER(QY,HIGHN) AND H=HHV(H,HIGHN+1); DRAWICON(CC,H*1.02,2);DDD:=BARSLAST(CC);GDTS:=IF(CC,BARSCOUNT(C),0);DINGBU:=IF(DDD,REF(H,DDD),H); DINGBUTS:=IF(DDD,REF(GDTS,DDD),GDTS); DINGBU1:=REF(DINGBU,DDD+1);GDCS1:=CEILING(DINGBUTS);DINGBUTS1:=REF(DINGBUTS,DDD+1);GDCS2:=CEILING(DINGBUTS1);DINGBU2:=REF(DINGBU1,DDD+1);。

  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

很牛的主图(包括跟庄.支撑.压力.买卖点等等)直接上图!家人再也不担心你炒股了!DRAWGBK(C>0,RGB(0,150,150),RGB(0,00,100),0,' ',0),LINETHICK2;M80:MA(C,80),LINETHICK0;M200:MA(C,200),LINETHICK0;DRAWBAND(M200,RGB(40,100,40),M80,RGB(100,100,0)),LINETHICK0; DRAWKLINE(H,O,L,C);MA03:MA(C,3),COLORYELLOW,DOTLINE,LINETHICK0;IF(MA03>=REF(MA03,1),MA03,DRAWNULL),COLOR0066FF,LINETHICK0;IF(MA03< REF(MA03,1),MA03,DRAWNULL),,COLORGREEN,LINETHICK0;X:=(3*C+L+O+H)/6;多空线:(20*X+19*REF(X,1)+18*REF(X,2)+17*REF(X,3)+16*REF(X,4)+15*REF(X,5)+14*REF (X,6)+13*REF(X,7)+12*REF(X,8)+11*REF(X,9)+10*REF(X,10)+9*REF(X,11)+8*REF(X,12) +7*REF(X,13)+6*REF(X,14)+5*REF(X,15)+4*REF(X,16)+3*REF(X,17)+2*REF(X,18)+ REF(X,20))/210,COLORGREEN,LINETHICK2;IF(多空线>=REF(多空线,1),多空线,DRAWNULL),COLORRED,LINETHICK3;IF(多空线< REF(多空线,1),多空线,DRAWNULL),,COLORGREEN,LINETHICK3;牛皮熊:DRAWICON(CROSS(MA03,多空线) ANDCLOSE/REF(CLOSE,1)>1.03,LOW*0.96,25);DRAWTEXT(FILTER(牛皮熊,8),多空线-0.05,'↖跟庄买进'),COLORGREEN; DRAWTEXT(CROSS(MA03,多空线) AND MA03>0,多空线-0.23,'★←'),COLORYELLOW; 花:=SLOPE(EMA(C,3),3);神:=SLOPE(EMA(C,7),7);DRAWICON(CROSS(花,神) AND CLOSE/REF(CLOSE,1)>1.03,LOW*0.96,25); DRAWTEXT(CROSS(花,神) AND CLOSE/REF(CLOSE,1)>1.03,LOW*0.96,'买'),COLORWHITE;花2:=EMA(SLOPE(1,1)+C,3),COLORRED;神2:=EMA(SLOPE(1,1)+C,7),COLORBLUE;A02:=3*EMA((C-LLV(L,30))/(HHV(H,30)-LLV(L,30))*100,5)-2*EMA((C-LLV(L,30))/(HHV( H,30)-LLV(L,30))*100,5);A4:=(HHV(H,34)-C)/(HHV(H,34)-LLV(L,34))*100;A5:=EMA(CLOSE,12)-EMA(CLOSE,26);A6:=EMA(A5,9);A7:=(A5<-0.1 AND A5>A6);财神:IF(A7,LLV(L,21),DRAWNULL)COLORRED,CIRCLEDOT;DRAWTEXT_FIX(1,0.07,0,0,HYBLOCK)COLOR0080FF;DRAWTEXT_FIX(1,0.01,0.08,0,'主题投资:')COLOR0000FF;DRAWTEXT_FIX(1,0.09,0.08,0,EXTERNSTR(0,1))COLOR0000FF;窗口显示:=C>REF(C,1)*1.095 AND C=H;T:=BARSLAST(窗口显示),LINETHICK0;涨停价:REF(C,T)NODRAW,LINETHICK0;涨停日期:REF(DATE-1000000,T)NODRAW,LINETHICK0;STICKLINE(L>REF(H,1),L,REF(H,1),20,1001), COLORYELLOW ,LINETHICK0; STICKLINE(REF(L,1)>H,REF(L,1),H,20,1001), COLORGREEN ,LINETHICK0;TJ01:=C<O AND REFX(C<O,1) AND REFX(C>O,2);DRAWLINE(TJ01,REFX(LLV(L,2),1),REF(TJ01,1),REF(REFX(LLV(L,2),1),1),1)COLORYELLO W,LINETHICK0;DRAWLINE(TJ01,REFX(HHV(C,2),1),REF(TJ01,1),REF(REFX(HHV(C,2),1),1),1)COLORYEL LOW,LINETHICK0;{波峰}TY:=H;A1:=REF(TY,10)=HHV(TY,2*10+1); B1:=FILTER(A1,10); C1:=BACKSET(B1,10+1); HD:=FILTER(C1,10);A2:=REF(TY,10)=LLV(TY,2*10+1); B2:=FILTER(A2,10); C002:=BACKSET(B2,10+1); LD:=FILTER(C002,10);波峰:REF(H,BARSLAST(HD)),COLOR00808F,POINTDOT,LINETHICK4;STICKLINE(H,波峰,波峰,8,0),COLOR00808F,LINETHICK4;BDGD:=C=HHV(C,13);GDSJ:=BARSLAST(FILTER(CROSS(0.8,BDGD),2))+1;高点:REF(C,GDSJ),COLORGREEN,LINETHICK4,POINTDOT;突破:CROSS(C,REF(高点,1)),COLOR00FFFF,POINTDOT,LINETHICK0;STICKLINE(GDSJ<=6,高点,高点,8,0),COLORGREEN,LINETHICK2;BDDD:=C=LLV(C,13);DDSJ:=BARSLAST(FILTER(CROSS(0.8,BDDD),2))+1;低点:REF(C,DDSJ),COLOR0055FF,POINTDOT,LINETHICK4;STICKLINE(DDSJ<=6,低点,低点,8,0),COLOR0055FF,LINETHICK4;AAA:=(REF(CLOSE,1)+REF(CLOSE,2)+OPEN)/3;前高:DRAWLINE(CURRBARSCOUNT=3,H,REF(CURRBARSCOUNT=3,1),REF(H,1),1),LINETHI CK2;昨收:DRAWLINE(CURRBARSCOUNT=2,C,REF(CURRBARSCOUNT=2,1),REF(C,1),1),LINETHI CK2;压力线:DRAWLINE(HIGH>=HHV(HIGH,10),HIGH,LOW<=LLV(LOW,3),HHV(HIGH,3),1),COLO RYELLOW,LINETHICK0;DRAWTEXT(压力线,L-0.2,'压力↙'),COLORYELLOW,LINETHICK0;MA010:=MA(CLOSE,10),COLORYELLOW,LINETHICK0;MA54:=MA(CLOSE,54),COLORFFCCCC,LINETHICK0;PL1:=(((CLOSE - MA54) / MA54) < 0.1);PL2:=(((CLOSE - MA010) / MA010) < 0.3);偏离率:=(((PL1 = 1) AND (PL2 = 1)) * 0.2);平台突破:=((((偏离率= 0) AND (REF(偏离率,1) = 0.2)) AND (REF((COUNT((偏离率= 0.2),10) = 10),1) = 1)) * 1);DRAWTEXT(平台突破,L,'=================='),COLORWHITE; DRAWTEXT(平台突破,L-0.05,'平台突破'),COLORGREEN;三日最低:=EMA((REF(L,4)+REF(L,3)+REF(L,2))/3,3);三日最高:=EMA((REF(H,4)+REF(H,3)+REF(H,2))/3,3);EXITLONG:CROSS(CROSS(三日最高,C),0.6);ENTERLONG:CROSS(CROSS(C,三日最低),0.5);STICKLINE(C/REF(C,1)>1.095,C,O,2,0),COLORYELLOW;涨停:=IF(REF(C,1)*1.095-C<0.01 ,1,0);STICKLINE(涨停,OPEN,CLOSE,2.5,0),COLORYELLOW;DRAWTEXT(涨停,L-0.1,'涨停'),COLORYELLOW;C3:=REF(C,1);跌停:=IF((C3-C)*100/C3>=(10-0.01*100/C3),1,0);STICKLINE(跌停,OPEN,CLOSE,2.5,0),COLORBLUE; DRAWTEXT(跌停,H+0.3,'跌停'),COLORBLUE;NN:=120;{跳空}STICKLINE(REF(L,1)>H,H,REF(L,1),5,0),COLORGRAY; STICKLINE(REF(H,1)<L,L,REF(H,1),5,0),COLORGRAY; {彩色K线}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((C-REF(C,1))*100/REF(C,1)>=(10-0.01*100/REF(C,1)),OPEN,CLOSE,1,0),CO LORYELLOW;STICKLINE((REF(C,1)-C)*100/REF(C,1)>=(10-0.01*100/REF(C,1)),OPEN,CLOSE,1,0),CO LORWHITE;{突破}STICKLINE(REF(COUNT(C<TYX3,5)=5,1) AND C>TYX3 AND C>O,C,O,1,0),COLOR00CCFF; STICKLINE(REF(COUNT(C<TYX3,5)=5,1) AND C>TYX3 ANDC>O,C,O,1,0),COLOR00CCFF;{红绿三角【副图】}A10304:=REF(HIGH,3)=HHV(HIGH,2*3+1);B10304:=FILTER(A10304,3);C10304:=BACKSET(B10304,3+1);D10304:=FILTER(C10304,3);{高点}A20304:=REF(LOW,3)=LLV(LOW,2*3+1);B20304:=FILTER(A20304,3);C20304:=BACKSET(B20304,3+1);D20304:=FILTER(C20304,3);{低点}E10304:=(REF(LLV(LOW,2*3),1)+REF(HHV(HIGH,2*3),1))/2;E20304:=(HIGH+LOW)/2;{高低点出现在同一K线上时可作取舍}H10304:=(D10304 AND NOT(D20304 AND E10304>=E20304)) OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;L10304:=(D20304 AND NOT(D10304 AND E10304=E20304));X10304:=REF(BARSLAST(H10304),1)+1;F10304:=BACKSET(H10304 ANDCOUNT(L10304,X10304)>0,LLVBARS(IF(L10304,LOW,10000),X10304));G10304:=F10304>REF(F10304,1);I10304:=BACKSET(G10304,2);LD0304:=I10304>REF(I10304,1);{过滤后低点}L20304:=LD0304 OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;X20304:=REF(BARSLAST(L20304),1)+1;F20304:=BACKSET(L20304 ANDCOUNT(H10304,X20304)>0,HHVBARS(IF(H10304,HIGH,0),X20304));G20304:=F20304>REF(F20304,1);I20304:=BACKSET(G20304,2);HD0304:=I20304>REF(I20304,1);{过滤后高点}UU0304:=BACKSET(BARSTATUS=2,BARSLAST(LD0304)+1);VV0304:=UU0304>REF(UU0304,1);UU20304:=BACKSET(BARSTATUS=2,BARSLAST(HD0304)+1);VV20304:=UU20304>REF(UU20304,1);{以下语句为三角形部分}底:REF(L,BARSLAST(VV0304)),COLORYELLOW,LINETHICK0;顶:REF(H,BARSLAST(VV20304)),COLORYELLOW,LINETHICK0;{下跌三角形:绿色三角形画完介入}STICKLINE(VV0304,顶,底,0,0),COLORGREEN,LINETHICK2;DRAWLINE(VV20304,H,VV0304,L,0),COLORGREEN,LINETHICK2;{斜}DRAWLINE(VV20304,H,VV0304,顶,0),COLORGREEN,LINETHICK2;{上涨三角形:红色三角形画完出局}STICKLINE(VV20304 ,顶,底,0,0),COLORBLUE,LINETHICK2;DRAWLINE(VV0304,L,VV20304,H,0),COLORBLUE,LINETHICK2;{斜}DRAWLINE(VV0304,L,VV20304,底,0),COLORBLUE,LINETHICK2;DRAWICON(C<O AND C>REF(C,1),H,6);{假阴真阳}均价:AMOUNT/VOL/100,NODRAW;假阴0:=O>C AND 均价>REF(C,1);DRAWTEXT(假阴0,L-0.2,'假阴↖'),COLORE8E8E8;STICKLINE(假阴0,O,C,1,0),COLORRED;VVOL:=IF(CURRBARSCOUNT=1 AND PERIOD=5,VOL*240/FROMOPEN,DRAWNULL);{模拟量}H_L:=0.1*CONST(HHV(VOL,240));长阴短柱:=C/REF(C,1)<=0.96 AND V<HHV(V,30)/1.9;DRAWTEXT(长阴短柱,V+1.6*0.098,'长阴短柱↙'),COLORLICYAN;MA05:=MA(C,5);MA5角度: ATAN((MA05/REF(MA05,1)-1)*100)*180/3.1416,NODRAW;T01:=CONST(LLVBARS(LOW,10));T1HIGH:=CONST(REF(HIGH,T01));MM:=CONST(CURRBARSCOUNT);T02:=CONST(BARSLAST(CURRBARSCOUNT>MM+T01 AND H>T1HIGH));T2HIGH:=CONST(REF(HIGH,T02));T03:=CONST(BARSLAST(CURRBARSCOUNT>MM+T02 AND HIGH>T2HIGH));T3HIGH:=CONST(REF(HIGH,T03));攻击线:DRAWLINE(CURRBARSCOUNT=T03+1, T3HIGH, ISLASTBAR,T3HIGH,1),LINETHICK3,COLOR8080FF;DRAWTEXT(ISLASTBAR, T3HIGH, '必杀攻击线')LINETHICK2,COLORCYAN;A6A:=REF(HIGH,6)=HHV(HIGH,2*6+1);B6A:=FILTER(A6A,6);C6A:=BACKSET(B6A,6+1);D6A:=FILTER(C6A,6);A7A:=REF(LOW,6)=LLV(LOW,2*6+1);B7A:=FILTER(A7A,6);C7A:=BACKSET(B7A,6+1);D7A:=FILTER(C7A,6);E6A:=(REF(LLV(LOW,2*6),1)+REF(HHV(HIGH,2*6),1))/2;E7A:=(HIGH+LOW)/2;H6A:=(D6A AND NOT(D7A AND E6A>=E7A)) OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;H7A:=D6A AND NOT(D7A AND E6A>=E7A);L6A:=D7A AND NOT(D6A AND E6A=E7A);X6A:=REF(BARSLAST(H6A),1)+1;F6A:=BACKSET(H6A AND COUNT(L6A,X6A)>0,LLVBARS(IF(L6A,LOW,10000),X6A)); G6A:=F6A>REF(F6A,1);I6A:=BACKSET(G6A,2);LD2A:=I6A>REF(I6A,1);L7A:=LD2A OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;X7A:=REF(BARSLAST(L7A),1)+1;F7A:=BACKSET(L7A AND COUNT(H7A,X7A)>0,HHVBARS(IF(H7A,HIGH,0),X7A));G7A:=F7A>REF(F7A,1);I7A:=BACKSET(G7A,2);HD2A:=I7A>REF(I7A,1);UU3A:=BACKSET(BARSTATUS=2,BARSLAST(LD2A)+1);VV3A:=UU3A>REF(UU3A,1);WW3A:=BACKSET(VV3A,REF(BARSLAST(LD2A),1)+2);XX3A:=WW3A>REF(WW3A,1);DRAWLINE(XX3A,L,VV3A,L,1),COLORCYAN,LINETHICK2;UU4A:=BACKSET(BARSTATUS=2,BARSLAST(HD2A)+1);VV4A:=UU4A>REF(UU4A,1);WW4A:=BACKSET(VV4A,REF(BARSLAST(HD2A),1)+2);XX4A:=WW4A>REF(WW4A,1);DRAWLINE(XX4A,H,VV4A,H,1),COLOR8000F0,LINETHICK2;HIGHN:=10;LOWN:=10;HIGHDISPLAY:=0;LOWDISPLAY:=0;ZGDISPLAY:=0;MADISPLAY:=0;AA:=REF(H,HIGHN)=HHV(H,2*HIGHN+1);QY:=BACKSET(AA,HIGHN+1);CC:=FILTER(QY,HIGHN) AND H=HHV(H,HIGHN+1); DRAWICON(CC,H*1.02,2);DDD:=BARSLAST(CC);GDTS:=IF(CC,BARSCOUNT(C),0);DINGBU:=IF(DDD,REF(H,DDD),H); DINGBUTS:=IF(DDD,REF(GDTS,DDD),GDTS); DINGBU1:=REF(DINGBU,DDD+1);GDCS1:=CEILING(DINGBUTS);DINGBUTS1:=REF(DINGBUTS,DDD+1);GDCS2:=CEILING(DINGBUTS1);DINGBU2:=REF(DINGBU1,DDD+1);。

相关文档
最新文档