通达信【弱转强战法】经历弱势阶段后突然强势反转的交易机会 主副图 源码

{弱转强主图源码如下}




MA5:MA(C,5),COLORWHITE;
MA10:MA(C,10),COLORYELLOW;
MA30:=MA(C,30),COLORMAGENTA;
MA60:MA(C,60),COLORGREEN;
MA120:MA(C,120),COLORBLUE;
涨停:=CLOSE>=ZTPRICE(REF(CLOSE,1),0.1);
跌停:=CLOSE<=DTPRICE(REF(CLOSE,1),0.1);
STICKLINE(涨停,O,C,3,0),COLORMAGENTA;
STICKLINE(跌停,O,C,3,0),COLORGREEN;
BK1:=STRCAT(STRSPACE(DYBLOCK),HYBLOCK);
BK2:=STRCAT(STRSPACE(BK1),GNBLOCK);
BK3:=STRCAT(STRSPACE(BK2),FGBLOCK);
BK4:=STRCAT(STRSPACE(BK3),ZHBLOCK);
HS:=100*DYNAINFO(8)/CAPITAL;
ZHWS:=STRCAT(VAR2STR(DYNAINFO(8)/10000,2),'万手');
JHS:=STRCAT('今换手:',STRCAT(VAR2STR(HS,2),'%'));
JHS1:=STRCAT(JHS,' ≈ ');
DRAWTEXT_FIX(1,0.67,0.05,0,STRCAT(JHS1,ZHWS))COLORYELLOW;
CJE:=DYNAINFO(8)*DYNAINFO(11);
DW:=IF(CJE/1000000>1,'亿','万');
AB:=IF(CJE/1000000>1,CJE/1000000,CJE/100);
DRAWTEXT_FIX(1,0.2,0.15,0,STRCAT(STRCAT('成交额:',CON2STR(AB,2)),DW))COLORYELLOW;
JJCJL:=DYNAINFO(15)/DYNAINFO(4)/100;
JJJEDW:=IF(DYNAINFO(15)>10000,'万元','元');
JJJE:=IF(DYNAINFO(15)>10000,CON2STR(DYNAINFO(15)/10000,1),CON2STR(DYNAINFO(15),1));
JJJE1:=STRCAT(JJJE,JJJEDW);
JJ:=STRCAT('竞价:',STRCAT(CON2STR(JJCJL,0),'手'));
JJ1:=STRCAT(JJ,' = ');DRAWTEXT_FIX(1,0.2,0.05,0,STRCAT(JJ1,JJJE1))COLORMAGENTA;
ZTT:=CLOSE/REF(CLOSE,1)>=1.0987;STICKLINE(ZTT,(REF(C,1)+C)/2,(REF(C,1)+C)/2,24,0);
顶部:=REFDATE(HHV(H,13),DATE);
底部:=REFDATE(LLV(L,13),DATE);
WYZHIBIAO1:=顶部-(顶部-底部)*0.191;
WYZHIBIAO2:=顶部-(顶部-底部)*0.382;
WYZHIBIAO3:=顶部-(顶部-底部)*0.5;
WYZHIBIAO4:=顶部-(顶部-底部)*0.618;
WYZHIBIAO5:=顶部-(顶部-底部)*0.809;
顶:IF(CURRBARSCOUNT<=30,REFDATE(顶部,DATE),DRAWNULL),COLORGREEN,DOTLINE;
L618:IF(CURRBARSCOUNT<=30,REFDATE(WYZHIBIAO4,DATE),DRAWNULL),COLORBROWN,DOTLINE;
底:IF(CURRBARSCOUNT<=30,REFDATE(底部,DATE),DRAWNULL),COLORCYAN,DOTLINE;
DRAWTEXT(CURRBARSCOUNT=30,顶部*0.99,' 实顶'),COLORGREEN;
DRAWTEXT(CURRBARSCOUNT=30,L618*0.99,' 高抛低吸'),COLORBROWN;
DRAWTEXT(CURRBARSCOUNT=30,底部*0.99,' 启动点'),COLORCYAN;
VAR0:=SMA(MAX(CLOSE-REF(C,1),0),12,1)/SMA(ABS(CLOSE-REF(C,1)),15,1)*100;
DRAWTEXT(CROSS(82,VAR0),L*1.0,'←跑'),COLORWHITE;
JH:=SMA(MAX(C-REF(C,1),0),5,1)/SMA(ABS(C-REF(C,1)),5,1)*100;
DRAWICON(CROSS(84,JH),H*1.02,6);
字:=STRCAT(STRCAT(STRCAT(STRCAT('名称: ',STKNAME),' 代码: '),CODE),' ' );
板块:=STRCAT('概念板块: ',GNBLOCK);
DRAWTEXT_FIX(ISLASTBAR,0,0,0,STRCAT(字,板块)),COLORYELLOW;
YC:=REF(CLOSE,1);
止损价位:=(YC*1.0035*97+0.2)/99.65;
DRAWTEXT_FIX(C!=0,0.2,0.1,0,STRCAT('止损价位 ',STRCAT(CON2STR(止损价位,2),' 元'))),COLORBLUE;
E:=(HIGH+LOW+OPEN+2*CLOSE)/5;
明日阻力:=2*E-LOW;
明日支撑:=2*E-HIGH;
明日突破:=E+(HIGH-LOW);
明日反转:=E-(HIGH-LOW);
今日阻力:=REF(明日阻力 , 1);
今日支撑:=REF(明日支撑 , 1);
DRAWTEXT_FIX(C!=0,0,0.05,0,STRCAT('今日阻力:',STRCAT(CON2STR(今日阻力,2),' 元'))),COLORFFFF00;
DRAWTEXT_FIX(C!=0,0,0.1,0,STRCAT('今日支撑:',STRCAT(CON2STR(今日支撑,2),' 元'))),COLORRED;
DRAWTEXT_FIX(C!=0,0,0.15,0,STRCAT('明日突破:',STRCAT(CON2STR(明日突破,2),' 元'))),COLORFF00FF;
DRAWTEXT_FIX(C!=0,0,0.2,0,STRCAT('明日阻力:',STRCAT(CON2STR(明日阻力,2),' 元'))),COLORFFFF00;
DRAWTEXT_FIX(C!=0,0,0.25,0,STRCAT('明日支撑:',STRCAT(CON2STR(明日支撑,2),' 元'))),COLORRED;
DRAWTEXT_FIX(C!=0,0,0.3,0,STRCAT('明日反转:',STRCAT(CON2STR(明日反转,2),' 元'))),COLORYELLOW;
A:=HHV(HIGH,13)=HIGH AND HIGH>REF(HIGH,1);
A1:=FILTER(A,12);
B:=LLV(LOW,13)=LOW AND LOW< REF(LOW,1);
B1:=FILTER(B,12);
TS1:=BARSLAST(A1);
箱顶:REF(HIGH,TS1),COLORFF00FF,NODRAW;
STICKLINE(1,箱顶,箱顶,1.5,0),COLOR00CCCC;
TS2:=BARSLAST(B1);
箱底:REF(LOW,TS2),COLORWHITE,NODRAW;
STICKLINE(1,箱底,箱底,2,0),COLORWHITE;
箱高:100*(箱顶-箱底)/箱底,NODRAW;
均价:=(3*C+H+L+O)/6;
VAR1:=(8*均价+7*REF(均价,1)+6*REF(均价,2)+5*REF(均价,3)+ 4*REF(均价,4)+3*REF(均价,5)+2*REF(均价,6)+REF(均价,8))/36;
VAR2:=(LLV(VAR1,2)+LLV(VAR1,4)+LLV(VAR1,6))/3;
吾1:=REF(VAR1,1)=REF(VAR2,1) AND VAR1>VAR2 AND CLOSE>VAR1;
吾2:=VAR1>VAR2 AND VAR1>REF(VAR1,1) AND VAR2>REF(VAR2,1) AND H/VAR1< 1.1 AND L>VAR2 AND CLOSE>VAR1;
吾3:=VAR1>VAR2 AND VAR1>REF(VAR1,1) AND VAR2>=REF(VAR2,1) AND H/VAR1>1.1;
吾4:=VAR1>VAR2 AND VAR1>REF(VAR1,1) AND VAR2>REF(VAR2,1) AND CLOSE>VAR2 AND CLOSE< VAR1;
吾5:=(VAR1>VAR2 AND VAR2>REF(VAR2,1) AND VAR1<>REF(VAR1,1) AND CLOSE<VAR2) OR (VAR1>VAR2 AND VAR1<REF(VAR1,1) AND VAR2< REF(VAR2,1) AND CLOSE<VAR2);
吾6:=REF(VAR1,1)>REF(VAR2,1) AND VAR1=VAR2 AND CLOSE< VAR2;
友1:=VAR1=VAR2 AND CLOSE< VAR2 OR (VAR1< REF(VAR1,1) AND VAR2< REF(VAR2,1) AND REF(VAR1,1)=REF(VAR2,1) AND CLOSE< VAR2);
友2:=VAR1=VAR2 AND CLOSE>VAR1;
SAT:=(AMOUNT/C)/(HHV(AMOUNT,20)/HHV(C,20));
量能饱和度:=IF(SAT>1,1,SAT)*100;
DRAWTEXT_FIX(BARSTATUS=2 AND 吾1,0.5,0.05,0,'调整结束短线介入'),COLORRED;
DRAWTEXT_FIX(BARSTATUS=2 AND 吾2,0.5,0.05,0,'上升通道走势良好'),COLORRED;
DRAWTEXT_FIX(BARSTATUS=2 AND 吾3,0.5,0.05,0,'股价偏离注意调整'),COLORRED;
DRAWTEXT_FIX(BARSTATUS=2 AND 吾4,0.5,0.05,0,'上升通道调整洗盘'),COLORGREEN;
DRAWTEXT_FIX(BARSTATUS=2 AND 吾5,0.5,0.05,0,'转向特征注意离场'),COLORGREEN;
DRAWTEXT_FIX(BARSTATUS=2 AND 吾6,0.35,0.05,0,'通道改变坚决离场'),COLORGREEN;
DRAWTEXT_FIX(BARSTATUS=2 AND 友1,0.5,0.05,0,'下跌通道只宜观望'),COLORGREEN;
DRAWTEXT_FIX(BARSTATUS=2 AND 友2,0.5,0.05,0,'短期底部准备进入'),COLORYELLOW;





{弱转强副图源码如下}


CC1:CCI(25),COLORSTICK,COLOR40FF00;
DRAWICON(CROSS(200,CCI),250,2);
DRAWICON(CROSS(CCI,-200),-250,1);
转强:CCI>0,COLOR0000D5,NODRAW;
STICKLINE(CCI>0,0,CCI,2,0),COLOR0000D5;
弱转强:CROSS(CCI,-200) AND CCI>REF(CCI,1),COLOR00DFDF,NODRAW;
STICKLINE(CROSS(CCI,-200) AND CCI>REF(CCI,1),CCI,0,2,0),COLOR00DFDF;
强转弱:CROSS(200,CCI) AND CCI<REF(CCI,1),COLOR00CA00,NODRAW;
STICKLINE(CROSS(200,CCI) AND CCI<REF(CCI,1),0,CCI,2,0),COLOR00CA00;
生命CCI线:CCI(84),COLORWHITE,LINETHICK1;
DBX:-100.00,COLORYELLOW,LINETHICK2;
JJX:300.00,COLORWHITE,LINETHICK2;
SMX:100.00,COLORRED,LINETHICK2;
NOTEXT1:200,COLORYELLOW,LINETHICK1;
NOTEXT2:-200,COLORMAGENTA,LINETHICK1;
NOTEXT3:100,COLORGREEN,LINETHICK1;
DRAWTEXT(CROSS(生命CCI线,DBX),DBX,'★准备买'),COLORRED;
DRAWTEXT(CROSS(生命CCI线,JJX),JJX,'★风险'),COLORRED;
DRAWTEXT(CROSS(生命CCI线,SMX),SMX,'★强'),COLORMAGENTA;


未来函数检测结果如下:
该公式包含未来函数:CAPITAL
该公式包含未来函数:DYNAINFO
解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式

联系我们  |  股票指标网  |  指标网   |  指标公式  |   加入收藏   |  设为主页

@2005-2023 粤ICP备2023063687号-2 股票指标网别名指标网仅为互联网文章,所有股票指标公式及文章仅供学习研究,并不构成投资建议,请勿以此为依据进行股票交易,由此引起的投资亏损与本站无关。股票指标网均来源互联网收集整理,如不慎侵犯了你的权益,请联系我们告知,我们将做删除处理
QQ:88652583 微信 88652583
sitemap站点地图