最新公告
  • 欢迎您光临九毛八公式指标网www.9m8.cn,本站全新改版试运行,期间内容全部免费,欢迎下载!欢迎加入本站VIP
  • 通达信在金昌九老师的ZIG转折点指标上增添的通信达文字提示源码

    正文概述    2024-04-13 08:07:10  

    通达信在金昌九老师的ZIG转折点指标上增添的通信达文字提示源码

    金昌九老师发的《ZIG能把涨跌幅转折点一个不落显示出来.你敢不敢驾驭它.》很有新意,感兴趣的同学也多。苦于通信达无文字提示,本人根据金昌九老师的创作思路,增添了通信达的文字提示。水平有限,还望指正;并对金昌九老师致予崇高的敬意!

    有同学导入不了,是通信达版本低的问题。很抱歉,发帖时忽视了,现补发指标源码,直接粘贴到公式里即可


    {zig转折主图}
    ZF:=5;
    {通道}
    CC:=WMA(C,3); HH:=HHV(H,3); LL:=LLV(L,3);
    ZC:=(2*CC+HH+LL)/4;
    WM3:WMA(ZC,3),COLORFF9900;

    MID : WMA(ZC,18),COLOR00FFFF,DOTLINE;
    UPPER: MID + 2*STD(ZC,18),COLOR0077FF;
    LOWER: MID - 2*STD(ZC,18),COLORFF9900;
    DRAWBAND(UPPER,RGB(80,0,85),MID,RGB(80,0,85));
    DRAWBAND(MID,RGB(0,80,0),LOWER,RGB(0,80,0));

    {股价趋势:}
    Z10:ZIG(3,ZF),COLOR00FF00,LINETHICK2;
    持有:=LAST(Z10 REF(Z10,1),Z10 REF(Z10,1),0);
    空仓:=LAST(Z10 REF(Z10,1),Z10 REF(Z10,1),0);


    LOW1:=TROUGH(3,ZF ,1);
    HIGH1:=PEAK(3,ZF,1);
    STICKLINE(BARSTATUS=2 AND 持有 0,LOW1,LOW1,150,1),COLOR00FF00,LINETHICK2;
    STICKLINE(BARSTATUS=2 AND 持有 0,LOW1*1.03,LOW1*(1+ZF/100),25,0),COLOR0099DD,LINETHICK1;
    STICKLINE(BARSTATUS=2 AND 持有 0,LOW1,LOW1*1.03,25,0),COLORFF9900,LINETHICK1;
    STICKLINE(BARSTATUS=2 AND 空仓 0,HIGH1,HIGH1*(1-ZF/100),25,0),COLORFF9900,LINETHICK1;
    STICKLINE(BARSTATUS=2 AND 空仓 0,HIGH1*(1-ZF/100),HIGH1*(1-ZF/100),25,0),COLOR00FFFF,LINETHICK1;
    STICKLINE(BARSTATUS=2 AND 空仓 0,HIGH1,HIGH1,150,1),COLOR0099FF,LINETHICK3;
    {泊砂.通信达文字提示}
    持:=(ZIG(3,5) REF(ZIG(3,5),1)) AND (REF(ZIG(3,5),1) =REF(ZIG(3,5),2)) AND (REF(ZIG(3,5),2) =REF(ZIG(3,5),3));
    空:=(ZIG(3,5) REF(ZIG(3,5),1)) AND (REF(ZIG(3,5),1) =REF(ZIG(3,5),2)) AND (REF(ZIG(3,5),2) =REF(ZIG(3,5),3));
    A:=Z10 REF(Z10,1);
    B:=Z10 REF(Z10,1);
    高点:='------------【高点飘逸临界线】 ',COLORGREEN;
    DRAWTEXT(ISLASTBAR AND B,HIGH1,高点),COLORGREEN;
    下反转:='------------【下反转10%线】',COLORWHITE;
    DRAWTEXT(ISLASTBAR AND B,HIGH1*0.9,下反转),COLORWHITE;

    低点:='------------【低点飘逸临界线】 ',COLORLIRED;
    DRAWTEXT(ISLASTBAR AND A ,LOW1,低点),COLORLIRED;
    上反转:='------------【上反转10%线】',COLORYELLOW;
    DRAWTEXT(ISLASTBAR AND A ,LOW1*1.1,上反转),COLORYELLOW;


    {上反转概况}
    低点临界价:=STRCAT(STRCAT(' 【低点飘逸临界价: ',CON2STR(LOW1,2)),'元】');
    升势天:=STRCAT(STRCAT(' 【升势第: ',CON2STR(BARSLASTCOUNT(持=0)+1,2)),'天】');
    上反转10%:=STRCAT(STRCAT(' 【上反转10%=: ',CON2STR(LOW1*1.1,2)),'元】');
    上反转现价:=STRCAT(STRCAT(' ★【上反转现价涨跌: ',CON2STR((C-LOW1)/LOW1*100,2)),'%】');
    上反转概况:=STRCAT('★【ZIG(3,5)】低点转折上涨小于10%趋势将向下飘逸: ',STRCAT(STRCAT(STRCAT(低点临界价,升势天),上反转10%),上反转现价));
    DRAWTEXT_FIX(ISLASTBAR AND A,0.00,0.00,0,上反转概况),COLORYELLOW;
    {下反转概况}
    高点临界价:=STRCAT(STRCAT(' 【高点飘逸临界价: ',CON2STR(HIGH1,2)),'元】');
    跌势天:=STRCAT(STRCAT(' 【跌势第: ',CON2STR(BARSLASTCOUNT(空=0)+1,2)),'天】');
    下反转10%:=STRCAT(STRCAT(' 【下反转10%=: ',CON2STR(HIGH1*0.9,2)),'元】');
    下反转现价:=STRCAT(STRCAT(' ★【下反转现价涨跌: ',CON2STR((C-HIGH1)/HIGH1*100,2)),'%】');
    下反转概况:=STRCAT('★【ZIG(3,5)】高点转折下跌小于10%趋势将向上飘逸: ',STRCAT(STRCAT(STRCAT(高点临界价,跌势天),下反转10%),下反转现价));
    DRAWTEXT_FIX(ISLASTBAR AND B,0.00,0.00,0,下反转概况),COLORGREEN;{泊砂.通信达文字提示}
    {高抛低吸}
    SJ:=WMA(((2*C+H+L)/4-LLV(L,5))/(HHV(H,5)-LLV(L,5))*100,2);
    ZJ:=WMA(0.618*REF(SJ,1)+0.382*SJ,2);
    DRAWTEXT(CROSS(SJ,ZJ) AND SJ 30,L,' 吸'),COLOR00FFFF;
    DRAWTEXT(CROSS(ZJ,SJ) AND SJ 70,H,' 抛'),COLOR00FFFF;

    {ZIG买卖}
    级买1:=ZIG(3,10) REF(ZIG(3,10),1) AND REF(ZIG(3,10),1) =REF(ZIG(3,10),2) AND REF(ZIG(3,10),2) =REF(ZIG(3,10),3);
    级卖1:=ZIG(3,10) REF(ZIG(3,10),1) AND REF(ZIG(3,10),1) =REF(ZIG(3,10),2) AND REF(ZIG(3,10),2) =REF(ZIG(3,10),3);
    级买2:=ZIG(3,20) REF(ZIG(3,20),1) AND REF(ZIG(3,20),1) =REF(ZIG(3,20),2) AND REF(ZIG(3,20),2) =REF(ZIG(3,20),3);
    级卖2:=ZIG(3,20) REF(ZIG(3,20),1) AND REF(ZIG(3,20),1) =REF(ZIG(3,20),2) AND REF(ZIG(3,20),2) =REF(ZIG(3,20),3);
    级买3:=ZIG(3,30) REF(ZIG(3,30),1) AND REF(ZIG(3,30),1) =REF(ZIG(3,30),2) AND REF(ZIG(3,30),2) =REF(ZIG(3,30),3);
    级卖3:=ZIG(3,30) REF(ZIG(3,30),1) AND REF(ZIG(3,30),1) =REF(ZIG(3,30),2) AND REF(ZIG(3,30),2) =REF(ZIG(3,30),3);
    级买4:=ZIG(3,55) REF(ZIG(3,55),1) AND REF(ZIG(3,55),1) =REF(ZIG(3,55),2) AND REF(ZIG(3,55),2) =REF(ZIG(3,55),3);
    级卖4:=ZIG(3,55) REF(ZIG(3,55),1) AND REF(ZIG(3,55),1) =REF(ZIG(3,55),2) AND REF(ZIG(3,55),2) =REF(ZIG(3,55),3);
    级买5:=ZIG(3,79) REF(ZIG(3,79),1) AND REF(ZIG(3,79),1) =REF(ZIG(3,79),2) AND REF(ZIG(3,79),2) =REF(ZIG(3,79),3);
    级卖5:=ZIG(3,79) REF(ZIG(3,79),1) AND REF(ZIG(3,79),1) =REF(ZIG(3,79),2) AND REF(ZIG(3,79),2) =REF(ZIG(3,79),3);
    买:=(级买1+级买2+级买3+级买4+级买5);
    卖:=(级卖1+级卖2+级卖3+级卖4+级卖5);
    DRAWICON(买 =2,(LOW * 0.98),1);
    DRAWICON(卖 =2,(H*1.01),2);

    {K线}
    STICKLINE(CLOSE OPEN OR CLOSE=OPEN AND CLOSE REF(CLOSE,1),LOW,HIGH,0.0,0),COLORRED;
    STICKLINE(CLOSE OPEN OR CLOSE=OPEN AND CLOSE =REF(CLOSE,1),LOW,HIGH,0.0,0),COLORCYAN;
    STICKLINE(OPEN =CLOSE ,CLOSE ,OPEN,3,0 ),COLOR008800;
    STICKLINE(OPEN =CLOSE ,CLOSE ,OPEN,2,0 ),COLOR00AA00;
    STICKLINE(OPEN =CLOSE ,CLOSE ,OPEN,1,0 ),COLOR00DD00;
    STICKLINE(OPEN =CLOSE ,CLOSE ,OPEN,0,0 ),COLOR00FF00;
    STICKLINE(CLOSE OPEN,CLOSE,OPEN,3,0) ,COLOR000088;
    STICKLINE(CLOSE OPEN,CLOSE,OPEN,2,0) ,COLOR0000AA;
    STICKLINE(CLOSE OPEN,CLOSE,OPEN,1,0) ,COLOR0000DD;
    STICKLINE(CLOSE OPEN,CLOSE,OPEN,0,0) ,COLOR0000FF;

    WMA(ZC,3),COLORFF9900;
    IF(WM3 REF(WM3,1),WM3,DRAWNULL),COLORRED,LINETHICK3;
    ZIG(3,ZF),COLOR00FF00,LINETHICK2;
    IF(Z10 REF(Z10,1),Z10,DRAWNULL),COLORRED,LINETHICK3;

    通达信在金昌九老师的ZIG转折点指标上增添的通信达文字提示源码

    九毛八公式指标,一个优质的公式指标平台!
    九毛八公式指标 » 通达信在金昌九老师的ZIG转折点指标上增添的通信达文字提示源码 加入收藏