最新公告
  • 欢迎您光临九毛八公式指标网www.9m8.cn,本站全新改版试运行,期间内容全部免费,欢迎下载!欢迎加入本站VIP
  • 主力仓位指标公式(股票主力仓位指标公式)

    正文概述    2024-05-04 03:31:04  

    通达信指标公式源码概况:


    指标类别: 通达信指标公式


    授权方式: 免费版


    指标评级: ★★★★★


    指标分类: 策略


    画线方法: 副图



    一、仓位指标公式

       

        IF(PERIODNAME 日线 )

        {

        统计: 该指标只在日线周期下有效。

        RETURN;

        }

        //大单净量

        r:=((ZDMR[-1]+BDMR[-1])-(ZDMC[-1]+BDMC[-1]))/SHGZG*100;

        //相对强弱

        LC:=REF(CLOSE,1);//前一日收盘价;

        RSI$1:=SMA(MAX(CLOSE-LC,0),3,1)/SMA(ABS(CLOSE-LC),3,1)*100;

        RSI$2:=SMA(MAX(CLOSE-LC,0),5,1)/SMA(ABS(CLOSE-LC),5,1)*100;

        RSI$3:=SMA(MAX(CLOSE-LC,0),8,1)/SMA(ABS(CLOSE-LC),8,1)*100;

        相对强弱:=0.5*RSI$1+0.31*RSI$2+0.19*RSI$3;

        wave$1:=SMA(100*(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8)),3,1);

        wave$2:=SMA(100*(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8)),5,1);

        wave$3:=SMA(100*(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8)),8,1);

        :=0.5*wave$1+0.31*wave$2+0.19*wave$3;

        机会区:20,POINTDOT,colorred;

        风险区:80,POINTDOT,colorgreen;

        风险系数:0.5*相对强弱+0.5*短线波段,coloryellow;

        //买入条件;

        CD1:=IF(风险系数 20ANDCLOSE OPENANDr 0,1,0);//波段小于20,股价翻红;

        CD2:=IF(风险系数 20ANDLOW =REF(LOW,1)ANDCLOSE LOWANDr 0,1,0);//波段小于20,股价未翻红,但未创新低;

        CD3:=IF(REF(风险系数,1) 20AND风险系数 REF(风险系数,1),1,0);//前一日波段小于20,今日转向;

        SIGNALBUY=(CD1=1ORCD2=1ORCD3=1);

        X=(SIGNALBUYANDCOUNT(SIGNALBUY,3)=1);

        DRAWICON(X,机会区, buy

        ///资金仓位

        IF(PERIODNAME 日线 )

        {

        统计: 该指标只在日线周期下有效。

        RETURN;

        }

        m5=0;

        m10=0;

        m20=0;

        m30=0;

        m60=0;

        a2=MA(C,1);

        a5=MA(C,5);

        a10=MA(C,10);

        a20=MA(C,20);

        a30=MA(C,30);

        a60=MA(C,60);

        IF(a5=NULL)m5=100;

        IF(a2 =a5)

        {

        m5=100;

        IF(a2 =a10)

        {

        m10=0;

        IF(a2 =a20)

        {

        m20=0;

        IF(a2 =a30)

        {

        m30=0;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-100;

        }

        }

        IF(a2 a30)

        {

        m30=-70;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-30;

        }

        }

        }

        IF(a2 a20)

        {

        m20=-50;

        IF(a2 =a30)

        {

        m30=0;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-50;

        }

        }

        IF(a2 a30)

        {

        M30=-20;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-30;

        }

        }

        }

        }

        IF(a2 a10)

        {

        m10=-50;

        IF(a2 =a20)

        {

        m20=10;

        IF(a2 =a30)

        {

        m30=0;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-60;

        }

        }

        IF(a2 a30)

        {

        m30=-30;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-30;

        }

        }

        }

        IF(a2 a20)

        {

        m20=-10;

        IF(a2 =a30)

        {

        m30=0;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-40;

        }

        }

        IF(a2 a30)

        {

        m30=-20;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-20;

        }

        }

        }

        }

        }

        IF(a2 a5)

        {

        m5=0;

        IF(a2 =a10)

        {

        m10=50;

        IF(a2 =a20)

        {

        m20=20;

        IF(a2 =a30)

        {

        m30=10;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-80;

        }

        }

        IF(a2 a30)

        {

        m30=-40;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-30;

        }

        }

        }

        IF(a2 a20)

        {

        M20=0;

        IF(a2 =a30)

        {

        m30=0;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-50;

        }

        }

        IF(a2 a30)

        {

        m30=-20;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-30;

        }

        }

        }

        }

        IF(a2 a10)

        {

        m10=0;

        IF(a2 =a20)

        {

        m20=50;

        IF(a2 =a30)

        {

        m30=0;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-50;

        }

        }

        IF(a2 a30)

        {

        m30=-20;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-30;

        }

        }

        }

        IF(a2 a20)

        {

        M20=0;

        IF(a2 =a30)

        {

        m30=30;

        IF(a2 =a60)

        {

        m60=0;

        }

        IF(a2 a60)

        {

        m60=-30;

        }

        }

        IF(a2 a30)

        {

        m30=0;

        IF(a2 =a60)

        {

        m60=10;

        }

        IF(a2 a60)

        {

        m60=0;

        }

        }

        }

        }

        }

        IF(a2 =a5ANDa2 =a10ANDa2 =a20ANDa2 =a30ANDa2 a60)m5=150;

        IF(a2 =a5ANDa2 =a10ANDa2 a20ANDa2 =a30ANDa2 a60)m5=130;

        IF(a2 =a5ANDa2 =a10ANDa2 =a20ANDa2 a30ANDa2 a60)m5=130;

        IF(a2 =a5ANDa2 a10ANDa2 a30ANDa2 a60)m5=110;

        IF(a2 a5ANDa2 =a10ANDa2 =a20ANDa2 =a30ANDa2 a60)m5=30;

        IF(a2 =a5ANDa2 =a10ANDa2 =a20ANDa5 =a10ANDa2 a30ANDa2 a60)m5=130;

        IF(a2 =a5ANDa2 =a10ANDa5 =a10ANDa2 a20ANDa2 a30ANDa2 a60)m5=120;

        IF(a2 =a5ANDa2 =a10ANDa5 a10ANDa2 a20ANDa2 a30ANDa2 a60)m5=110;

        IF(a2 =a5ANDa2 =a10ANDa2 =a20ANDa2 =a30ANDa2 a60ANDa5 a10ANDa10 a30)m5=130;

        m=m5+m10+m20+m30+m60;

        IF(m =50){STICKLINE(m,0,m,10,1),colorred;}ELSE{STICKLINE(m,0,m,10,1),colorgreen;}

        VAR1:=(2*CLOSE+HIGH+LOW+OPEN)/5;

        VAR2:=EMA(EMA(EMA(VAR1,4),4),4);

        SJ:(VAR2-REF(VAR2,1))/REF(VAR2,1)*100,COLORSTICK;

        SD:MA(SJ,2);

        SK:MA(SJ,1);

        DRAWBAND((SJ-SD)*30000+40000,RGB(255,215,0),40000,RGB(135,206,235));

        SHORT:=5;

        LONG:=55;

        MID:=10;

        DIF:EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);

        DEA:EMA(DIF,MID);

        DRAWBAND((DIF-DEA)*20000+20000,RGB(255,215,0),20000,RGB(135,206,235));

        {资金流向}

        ZC_1:=IF(L DYNAINFO(7),0,IF(H DYNAINFO(7),DYNAINFO(7)-(DYNAINFO(7)-H+0.02)/(H-L+0.02),0));

        ZC_2:=DMA(ZC_1,V/CAPITAL)*100;

        出货:=IF(ZC_2 0ANDZC_2 REF(ZC_2,1),ZC_2/20,0);

        轴:0,COLOR00FF00;

        PJJ:=DMA((H+L+C*2)/4,0.9);

        JJ:=REF(EMA(PJJ,3),1);

        QJJ:=VOL/((H-L)*2-ABS(C-O));

        XVL:=IF(C O,QJJ*(H-L),IF(C O,QJJ*(H-O+(C-L)),VOL/2))+IF(C O,0-QJJ*(H-C+(O-L)),IF(C O,0-QJJ*(H-L),0-VOL/2));

        ZLL:=VOL/CAPITAL;

        HSL1:=IF(ZLL 10,10,ZLL);

        HSL:=XVL/20/1.15;

        攻击流量:=HSL*0.55+REF(HSL,1)*0.33+REF(HSL,2)*0.22;

        GJJ:=EMA(攻击流量,8);

        LLJX:=EMA(攻击流量,3);

        流量:LLJX,COLORC875B7,COLORRED,NODRAW;

        STICKLINE(流量 0,流量,0,2.3,0)COLORRED;

        STICKLINE(流量 0,流量,0,2.3,0),COLORFF4242;

        流量基线:GJJ,COLOR00BBBB,COLORGREEN;

        STICKLINE(HSL*0.4 =0,HSL*0.4*1.5,0,0.5,0)COLORYELLOW;

        STICKLINE(HSL*0.4 0,HSL*0.4*1.5,0,0.5,0)COLORGREEN;

        ZJLL:=REF(LLJX,1);

        QZJJ:=(((LLJX-ZJLL)/ZJLL)*100);

        流量幅%:IF(((LLJX 0)AND(ZJLL 0)),ABS(QZJJ),IF((((LLJX 0)AND(ZJLL 0))AND(LLJX ZJLL)),(0-QZJJ),QZJJ))COLORMAGENTA,NODRAW;

        力度:HSL/1000,COLOR9B37FF,COLORRED,NODRAW;

        周流量:SUM(LLJX,5),COLORFFBFDF,COLORMAGENTA,NODRAW;

        BB:=REF(周流量,1);

        ZQZJJ:=(周流量-BB)/BB*100;

        周幅%:IF(周流量 0ANDBB 0,ABS(ZQZJJ),IF(周流量 0ANDBB 0AND周流量 BB,-ZQZJJ,ZQZJJ))COLORMAGENTA,NODRAW;

        VARQ1:=REF((LOW+OPEN+CLOSE+HIGH)/4,1);

        VARQ2:=SMA(ABS(LOW-VARQ1),13,1)/SMA(MAX(LOW-VARQ1,0),10,1);

        VARQ3:=EMA(VARQ2,10);

        VARQ4:=LLV(LOW,33);

        VARQ5:=EMA(IF(LOW =VARQ4,VARQ3,0),3)*100;

        主力进场:STICKLINE(VARQ5 REF(VARQ5,1)AND出货 =0,0,VARQ5,7,0),COLORBLUE;

        JJJ:MA(SUM(HSL,55),8),COLORRED,LINETHICK2;

        DRAWICON(CROSS(JJJ,轴),-5000,1);

        AL:=(C+L+H)/3;

        AO:=SMA(AL,5,1)-SMA(AL,13,1);

        BBD:(AO-SMA(AO,3,1))*100,COLORFFCCFF,NODRAW;

        BBDA:SMA(BBD,5,2),COLORRED,LINETHICK0;

        RSV1:=BBD;

        RSV2:=BBDA;

        {BBD彩色柱体}

        VAR11:=IF(DATE 1091230ANDDATE 900101,1,0);

        BBD1:=IF(BBD =REF(BBD,1)*VAR11,BBD,DRAWNULL);

        BBD2:=IF(BBD REF(BBD,1)*VAR11,BBD,DRAWNULL);

        STICKLINE(BBD1,0,BBD,3,0),COLOR000088;

        STICKLINE(BBD1,0,BBD,1.5,0),COLOR0000AA;

        STICKLINE(BBD1,0,BBD,1,0),COLOR0000CC;

        STICKLINE(BBD1,0,BBD,0.5,0),COLOR0000FF;

        STICKLINE(BBD2,0,BBD,3,0),COLOR888800;

        STICKLINE(BBD2,0,BBD,1.5,0),COLORAAAA00;

        STICKLINE(BBD2,0,BBD,1,0),COLORCCCC00;

        STICKLINE(BBD2,0,BBD,0.5,0),COLORFFFF00;

        {SV1:=BARSLAST(REF(CROSS(RSV1,RSV2),1));

        SV1A:=REF(CLOSE,SV1+1) CLOSEANDRSV1 REF(RSV1,SV1+1)AND

        CROSS(RSV1,RSV2);

        上涨BBD:IF(SV1A,RSV2,DRAWNULL),COLORRED;

        DRAWTEXT(SV1A,RSV2, ─B底背 ),COLOR0033FF;

        SV2:=BARSLAST(REF(CROSS(RSV2,RSV1),1));

        SV2A:=REF(CLOSE,SV2+1) CLOSEANDREF(RSV1,SV2+1) RSV1ANDCROSS(RSV2,RSV1);

        下跌BBD:IF(SV2A,RSV2,DRAWNULL),COLORFFFF00;}

        DRAWICON(((((LLV(BBD,4) 0)AND(BBD REF(BBD,1)))

        AND(REF(BBD,1) REF(BBD,2)))AND(REF(BBD,2) REF(BBD,3)))

        ,BBD,2);

        DRAWICON(((((HHV(BBD,4) 0)AND(BBD REF(BBD,1)))AND(REF(BBD,1) REF(BBD,2)))AND(REF(BBD,2)

        REF(BBD,3))),BBD,1);

        SHORT:=12;

        LONG:=26;

        M:=9;

        DIF:EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);

        DEA:EMA(DIF,M);

        MACD:2*(DIF-DEA),COLORSTICK;

        STICKLINE(MACD 0ANDMACD REF(MACD,1),0,MACD,6,0),COLORRED;

        STICKLINE(MACD 0ANDMACD REF(MACD,1),0,MACD,6,0),COLORYELLOW;

        STICKLINE(MACD 0ANDMACD REF(MACD,1),0,MACD,6,0),COLORGREEN;

        STICKLINE(MACD 0ANDMACD REF(MACD,1),0,MACD,6,0),COLORBLUE;


    image.png

    公式解读:

    [源码注释]通达信公式动态公式解读


    输出峰: SSRP.SSRP

    输出MA1:SSRP的6日简单移动平均

    输出:SSRP的19日简单移动平均

    当满足条件SSRP上穿MA1时,在MA1位置画1号图标

    输出XG:SSRP上穿MA1,NODRAW


    推荐阅读:主力增减仓指标公式


    VAR1:=MA(CLOSE,5),COLOR00FFFF;

    VAR2:MA(CLOSE,13),COLOR00FF33;

    VAR5:MA(CLOSE,34),COLORFF9900;

    VAR6:=MA(CLOSE,54),COLORFF9900;

    VAR7:((EMA(CLOSE,5)*7+EMA(CLOSE,5)*3)/10),COLORBBBBBB;

    VAR8:= DMA(EMA(CLOSE,12),SUM(VOL/CAPITAL,5)/3),LINETHICK2;

    VARA:=REF(CLOSE,1);

    VARE:=SMA(MAX(CLOSE-VARA,0),6,1)/SMA(ABS(CLOSE-VARA),6,1)*100;

    DRAWTEXT(DATE 700101 AND CROSS(84,VARE),HIGH, ☆减仓 ),COLORGREEN;

    VARF:=(2*CLOSE+HIGH+LOW)/4;

    VAR10:=LLV(LOW,34);

    VAR11:=HHV(HIGH,34);

    VAR12:=EMA((VARF-VAR10)/(VAR11-VAR10)*100,6);

    VAR13:=EMA(0.667*REF(VAR12,1)+0.333*VAR12,4);

    VAR14:=LLV(LOW,120);

    VAR15:=HHV(HIGH,120);

    VAR16:=VAR15-VAR14;

    DRAWTEXT(IF(COUNT(CLOSE REF(CLOSE,1),8)/8 0.3 AND COUNT(VAR12 VAR13,3) AND REF(LOW,1)=LLV(LOW,120) AND CLOSE OPEN,1,0),LOW, ★机构进场 ),COLORYELLOW;

    STICKLINE(VAR7 VAR2,VAR2,VAR7,0.01,1),COLORFF00FF;

    STICKLINE(VAR7 VAR2,VAR2,VAR7,0.01,1),COLOR33FF33;

    RSV:=(CLOSE-LLV(LOW,13))/(HHV(HIGH,13)-LLV(LOW,13))*100; 

    K:=SMA(RSV,3,1); 

    D:=SMA(K,3,1); 

    J:=3*K-2*D; 

    RSV12:=(CLOSE-LLV(LOW,34))/(HHV(HIGH,34)-LLV(LOW,34))*100; 

    K12:=SMA(RSV12,3,1); 

    D12:=SMA(K12,3,1); 

    J12:=3*K12-2*D12; 

    RSV24:=(CLOSE-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))*100; 

    K24:=SMA(RSV24,3,1); 

    D24:=SMA(K24,3,1); 

    J24:=3*K24-2*D24; 

    压力位:IF(CROSS(J24,J),H,REF(H,BARSLAST(CROSS(J24,J)))),COLOR00FF33,LINETHICK1; 

    支撑位:IF(CROSS(J,J24),L,REF(L,BARSLAST(CROSS(J,J24)))),COLORCC33CC,LINETHICK1;

    支撑价:LLV(LOW,19) , COLOR009900,LINETHICK2;

    阻力价:HHV(HIGH,19),COLORFF9900, LINETHICK2;

    VAR4:EMA(C,21),COLOR0000FF, LINETHICK2;

    DRAWGBKLAST(1,STRIP(RGB(100,100,100),RGB(50,50,50),0)); 

    年:REF(MONTH,(BARSCOUNT(CLOSE) - 1)),LINETHICK0,colorFFFF00; 

    月:REF(DAY,(BARSCOUNT(CLOSE) - 1)),LINETHICK0,colorFFFF00; 

    VAR1:=(VOL / (((HIGH - LOW) * 2) - ABS((CLOSE - OPEN))));成交:=VOL; 

    买盘:=IF((CLOSE OPEN),(VAR1 * (HIGH - LOW)),IF

    ((CLOSE OPEN),(VAR1 * ((HIGH - OPEN) + (CLOSE - LOW))),(VOL / 2))); 

    卖盘:=IF((CLOSE OPEN),(0 - (VAR1 * ((HIGH - CLOSE) + (OPEN - LOW)))),IF

    ((CLOSE OPEN),(0 - (VAR1 * (HIGH - LOW))),(0 - (VOL / 2)))); 

    差:=(买盘 + 卖盘);STICKLINE((VOL 0),VOL,0,8,1),colorFFFFFF; 

    STICKLINE((买卖差 0),0,买卖差,8,0),color0000FF; 

    STICKLINE((买卖差 0),0,买卖差,8,0),LINETHICK3,color33aa33; 

    STICKLINE((买卖差 0),0,买卖差,5,0),LINETHICK3,color33cc33; 

    STICKLINE((买卖差 0),0,买卖差,3,0),LINETHICK3,color33ee33; 

    :=(VOL / MA(VOL,5));VAR10:=买盘;VAR20:=卖盘;JX1:=BARSSINCE(买盘); 

    JY1:=IF(((121 JX1) AND (JX1 0)),JX1,120); 

    JY2:=IF(((4 JX1) AND (JX1 0)),JX1,3);VAR30:=MA(VOL,JY2);动神:=买盘; 

    鬼力:=VAR20;神比:=(动神 / VAR30);鬼比:=(鬼力 / VAR30);VAR2:=(HIGH - LOW); 

    VAR3:=ABS((OPEN - CLOSE));VAR4:=(HIGH - IF((CLOSE OPEN),CLOSE,OPEN)); 

    VAR5:=(IF((CLOSE OPEN),OPEN,CLOSE) - LOW); 

    VAR6:=((VAR3 / VAR2) * VOL);VAR7:=((VAR4 / VAR2) * VOL); 

    VAR8:=((VAR5 / VAR2) * VOL); 

    VAR9:=IF(((VOL / CAPITAL) 0.001),1,EXP(ABS(LOG(((VOL / CAPITAL) * 100))))); 

    VARA:=(((CLOSE - MA(CLOSE,5)) / MA(CLOSE,5)) * 100); 

    VARB:=(((MA(CLOSE,5) MA(CLOSE,10)) AND (MA(CLOSE,10) MA(CLOSE,30)))

    AND (MA(CLOSE,30) MA(CLOSE,60))); VARC:=((MA(CLOSE,5) MA(CLOSE,10))

    AND (MA(CLOSE,10) MA(CLOSE,30)));VARD:=REF(CLOSE,1); 

    VARE:=((SMA(MAX((CLOSE - VARD),0),6,1) / SMA(ABS((CLOSE - VARD)),6,1)) * 100); 

    DRAWTEXT(((DATE 700101) AND CROSS(84,VARE)),HIGH, ■卖出 ),colorF2A3A4; 

    VAR40:=((IF((((VAR6 = VAR7) AND (VAR6 = VAR8)) AND (CLOSE OPEN)),VAR6,动神) + 动神) / 2); 

    VAR41:=((IF(((VAR7 VAR6) AND (VAR7 VAR8)),VAR7,动神) + 动神) / 2); 

    VAR42:=((IF(((VAR8 VAR6) AND (VAR8 VAR7)),VAR8,动神) + 动神) / 2); 

    VAR50:=((IF((((VAR6 = VAR7) AND (VAR6 = VAR8)) AND (CLOSE OPEN)),VAR6,鬼力) + 鬼力) / 2); 

    三日上攻:=MA((((VAR40 + VAR41) + VAR42) / 3),JY2); 

    三日下攻:=MA(VAR50,JY2); 

    多头:STICKLINE((CLOSE MA(CLOSE,30)),0,VOL,8,0),color0000FF;

    STICKLINE((CLOSE MA(CLOSE,30)),0,VOL,5,0),color0033FF;

    STICKLINE((CLOSE MA(CLOSE,30)),0,VOL,2,0),color0099FF;

    空头:STICKLINE((CLOSE MA(CLOSE,30)),0,VOL,8,0),coloraaaaaa; 

    STICKLINE((CLOSE MA(CLOSE,30)),0,VOL,5,0),colorbbbbbb; 

    STICKLINE((CLOSE MA(CLOSE,30)),0,VOL,2,0),colorcccccc; 

    STICKLINE((鬼力 0),鬼力,0,8,0),colorFF3399;

    加仓:STICKLINE((((VAR6 = VAR7) AND (VAR6 = VAR8)) AND (CLOSE OPEN)),0,VAR6,6,0),color55FFFF; 

    STICKLINE((((VAR6 = VAR7) AND (VAR6 = VAR8)) AND (CLOSE OPEN)),0,VAR6,3,0),color33FFff; 

    STICKLINE((((VAR6 = VAR7) AND (VAR6 = VAR8)) AND (CLOSE OPEN)),0,VAR6,1,0),color00FFFF; 

    减仓:STICKLINE((((VAR6 = VAR7) AND (VAR6 = VAR8)) AND (CLOSE OPEN)),0,VAR6,6,0),colorFF8080; 

    STICKLINE((((VAR6 = VAR7) AND (VAR6 = VAR8)) AND (CLOSE OPEN)),0,VAR6,3,0),colorFFcc66;

    STICKLINE((((VAR6 = VAR7) AND (VAR6 = VAR8)) AND (CLOSE OPEN)),0,VAR6,1,0),colorFFaa66; 

    洗盘:STICKLINE(((VAR8 VAR6) AND (VAR8 VAR7)),0,VAR8,6,0),colorcccc00; 

    STICKLINE(((VAR8 VAR6) AND (VAR8 VAR7)),0,VAR8,3,0),colorbbbb33; 

    STICKLINE(((VAR8 VAR6) AND (VAR8 VAR7)),0,VAR8,1,0),coloraaaa55; 

    高卖:STICKLINE(((VAR7 VAR6) AND (VAR7 VAR8)),0,VAR7,6,0),colorFFccFF; 

    STICKLINE(((VAR7 VAR6) AND (VAR7 VAR8)),0,VAR7,3,0),colorFFbbFF; 

    STICKLINE(((VAR7 VAR6) AND (VAR7 VAR8)),0,VAR7,1,0),colorFFaaFF; 

    相对地量:STICKLINE(((VAR9 2) AND (VOL (MA(VOL,5) / 2))),0,VOL,3,0),colorFF00FF; 

    地量:=DRAWTEXT(((VAR9 2) AND (VOL (MA(VOL,5) / 2))),VOL, 地量  

    放量:=STICKLINE((VOL (MA(VOL,5) * 2.5)),0,VOL,3,0); STICKLINE((动神 0),动神,0,1.5,0),color0000FF; 

    上攻:=MA((((VAR40 + VAR41) + VAR42) / 3),JY2); 

    下攻:=MA(VAR50,JY2); 上攻均量:=MA(VAR10,JY1);下攻均量:=MA(VAR20,JY1); 

    逢高出货:=DRAWTEXT(((((((((VAR7 VAR6) AND (VARA 2)) AND (VAR9 VAR8)) AND (CLOSE MA(CLOSE,5))) AND (CLOSE MA(CLOSE,30))) AND (HIGH MA(CLOSE,60))) AND (VOL MA(VOL,5))) AND (VAR7 = MA(VOL,5))),VOL, ▼出货  

    逢低跟进:=DRAWTEXT(((((((VAR8 VAR6) AND (VAR8 VAR7)) AND (VARA (0 - 2))) AND (CLOSE MA(CLOSE,30))) AND (VAR8 (MA(VOL,5) / 2))) AND (MA(VOL,5) MA(VOL,10))),VOL, ●低进  

    强势参与:=DRAWTEXT((((((VAR6 (MA(VOL,5) * 2)) AND (VAR6 = VAR7)) AND (VAR6 = VAR8)) AND (CLOSE OPEN)) OR ((VOL (MA(VOL,5) * 3)) AND VARB)),VOL, ◆强势  

    DRAWTEXT(((((((VAR6 = VAR7) AND (VAR6 = VAR8)) AND (CLOSE OPEN)) AND ((VAR6 / VOL) 0.7)) AND VARC) AND (VAR6 MA(VOL,5))),(VAR6 * 2), ▼空头 ),color00FF00; 

    DRAWTEXT((((((量比 1) AND ((动神 / 三日上攻) 1.58)) AND IF((三日上攻 上攻均量),(三日上攻 三日下攻),(三日上攻 REF(三日上攻,1)))) AND (三日下攻 REF(三日下攻,1))) AND ((((CLOSE - REF(CLOSE,3)) / REF(CLOSE,3)) * 100) 14)),(动神 * 1.3), ★参与 ),color99FF00; 

    MFI:=(((HIGH - LOW) * 1000000) / VOL);

    :DYNAINFO(37),LINETHICK0; 

    DRAWTEXT((((VOL / REF((SUM(VOL,5) / 5),1)) = 2) AND (换手率 1)),(VOL * 1.1), ●量变 ),color00FFFF; 

    量:IF((CLOSE 200),(VOL / 1000000),(VOL / 100)),LINETHICK0; 

    振幅:(((HIGH - LOW) / LOW) * 100),LINETHICK0; 

    STICKLINE((((CLOSE = OPEN) AND (换手率 = 3)) AND (换手率 5)),0,量,80,1),color33AAFF;

    YM:=MA(((WINNER((CLOSE * 0.9)) * 100) * CLOSE),3);

    DC:=(IF((YM 10),YM,0) / 2);

    资金增仓:DC,STICK,LINETHICK7,COLORRED;

    资金均量:MA(DC,5),COLORGREEN;

    资金增仓线:DC,COLORYELLOW,LINETHICK1;

    资金均量线:MA(DC,5),COLORMAGENTA;


    image.png


    每日公式解答:

        公式编写要求:

        HR:=HHV(HIGH,55);HRY:=LLV(LOW,55);HRY11:=HR*HRY;HRY33:SQRT(HRY11),COLORGREEN,LINETHICK2;IF(C HRY33ANDHRY33 =REF(HRY33,1),HRY33,DRAWNULL),LINETHICK2,COLORRED;WLT1:=EMA(C,3);WLT2:=EMA(C,5);WLT3:=EMA(WLT2,5);DRAWBAND(WLT1,RGB(255,255,0),WLT2,RGB(0,0,220));HP:=(HHV(CLOSE,10)-LLV(CLOSE,10))/CLOSE 0.10;LB:=VOL/MA(VOL,5);X1:=(C+L+H)/3;BB5:=ATAN(EMA(X1,7)-REF(EMA(X1,7),1))*3.1416*10;EMA3:=EMA(C,3);TT:=FILTER(BB5 1ANDEMA(X1,7) REF(EMA(X1,7),1),10);MM:=WLT1 REF(WLT1,1)ANDREF(WLT1,1) REF(WLT1,2);GG1:=CROSS(WLT1,WLT2);TYP:=(HIGH+LOW+CLOSE)/3;CCI1:=(TYP-MA(TYP,6))/(0.015*AVEDEV(TYP,5));差值1:=ABS(REF(CCI1,1)-CCI1),LINETHICK0;CCI2:=(TYP-MA(TYP,10))/(0.015*AVEDEV(TYP,10));差值2:=ABS(REF(CCI2,1)-CCI2),LINETHICK0;CCI3:=(TYP-MA(TYP,20))/(0.015*AVEDEV(TYP,20));差值3:=ABS(REF(CCI3,1)-CCI3),LINETHICK0;CCI4:=(TYP-MA(TYP,30))/(0.015*AVEDEV(TYP,30));差值4:=ABS(REF(CCI4,1)-CCI4),LINETHICK0;CCI5:=(TYP-MA(TYP,60))/(0.015*AVEDEV(TYP,60));差值5:=ABS(REF(CCI5,1)-CCI5),LINETHICK0;CCI:=(CCI1+CCI2+CCI3+CCI4+CCI5)/2,COLORRED,LINETHICK2;WLT91:=HHV(CCI,13);WLT92:=LLV(CCI,13) -100;WLT95:=COUNT(WLT92,13) WLT93:=CCI WLT91;WLT96:=CROSS(CCI,100);TJ91:=WLT95ANDWLT96;JLP:=FILTER(TJ91,5);超买:=MA(C,10)*IF(CAPITAL=0,1.04,1.1),POINTDOT,COLORGREEN,LINETHICK2;超卖:=MA(C,10)*IF(CAPITAL=0,0.95,0.9),POINTDOT,COLORRED,LINETHICK2;TEND:EMA(((SLOPE(CLOSE,21)*20)+CLOSE),42),POINTDOT,COLORFF00FF,LINETHICK4;DD:=TEND REF(TEND,1)ANDREF(TEND,1) REF(TEND,2);GG2:=CROSS(WLT1,TEND);HRY1:=LLV(LOW,55);HRY2:=HHV(HIGH,21);GG3:=C HRY2*0.8ANDC HRY33;JJ1:=C HRY1*1.62;TJ1:=GG1;TJ2:=GG2ANDJJ1;TJ3:=GG1ANDGG3;XG:=TJ1ORTJ3;XG2:=C HRY2*0.86ORLB XG1:=XGANDXG2ANDC HRY33ANDJLP;XG3:=XGANDC HHV(HIGH,250)*0.3;XG11:=XG1ORXG3;DRAWICON(XG11,LOW*0.97,23);DRAWTEXT(XG1,LOW*0.95, 全 ),COLORRED;DRAWTEXT(XG1,LOW*0.93, 仓 ),COLORRED;STICKLINE(XG,C,O,4,0),COLOR009999;STICKLINE(XG,C,O,3,0),COLOR00BBBB;STICKLINE(XG,C,O,1.5,0),COLOR00DDDD;STICKLINE(XG,C,O,0.3,0),COLOR00FFFF;SAL1:=HIGH SAL2:=C OAND(O-C)/C 0.03;QQ:=C WLT2;QQ1:=CROSS(WLT2,WLT1);QQ3:=HIGH HRY1*1.38;SAL01:=SAL1ANDSAL2ANDQQANDQQ3;SAL02:=QQ3ANDQQ1;SAL:=SAL01ORSAL02;DRAWICON(SAL,HIGH*1.03,15);STICKLINE(SAL,C,O,4,0),COLOR009900;STICKLINE(SAL,C,O,3,0),COLOR00BB00;STICKLINE(SAL,C,O,1.5,0),COLOR00DD00;STICKLINE(SAL,C,O,0.3,0),COLOR00FF00;

        公式编写方法:

        HR:=HHV(HIGH,55);

        HRY:=LLV(LOW,55);

        HRY11:=HR*HRY;

        HRY33:=SQRT(HRY11);

        WLT1:=EMA(C,3);

        WLT2:=EMA(C,5);

        WLT3:=EMA(WLT2,5);

        HP:=(HHV(CLOSE,10)-LLV(CLOSE,10))/CLOSE 0.10;

        LB:=VOL/MA(VOL,5);

        X1:=(C+L+H)/3;

        BB5:=ATAN(EMA(X1,7)-REF(EMA(X1,7),1))*3.1416*10;

        EMA3:=EMA(C,3);

        TT:=FILTER(BB5 1ANDEMA(X1,7) REF(EMA(X1,7),1),10);

        MM:=WLT1 REF(WLT1,1)ANDREF(WLT1,1) REF(WLT1,2);

        GG1:=CROSS(WLT1,WLT2);

        TYP:=(HIGH+LOW+CLOSE)/3;

        CCI1:=(TYP-MA(TYP,6))/(0.015*AVEDEV(TYP,5));

        差值1:=ABS(REF(CCI1,1)-CCI1),LINETHICK0;

        CCI2:=(TYP-MA(TYP,10))/(0.015*AVEDEV(TYP,10));

        差值2:=ABS(REF(CCI2,1)-CCI2),LINETHICK0;

        CCI3:=(TYP-MA(TYP,20))/(0.015*AVEDEV(TYP,20));

        差值3:=ABS(REF(CCI3,1)-CCI3),LINETHICK0;

        CCI4:=(TYP-MA(TYP,30))/(0.015*AVEDEV(TYP,30));

        差值4:=ABS(REF(CCI4,1)-CCI4),LINETHICK0;

        CCI5:=(TYP-MA(TYP,60))/(0.015*AVEDEV(TYP,60));

        差值5:=ABS(REF(CCI5,1)-CCI5),LINETHICK0;

        CCI:=(CCI1+CCI2+CCI3+CCI4+CCI5)/2;

        WLT91:=HHV(CCI,13);

        WLT92:=LLV(CCI,13) -100;

        WLT95:=COUNT(WLT92,13)

        WLT93:=CCI WLT91;

        WLT96:=CROSS(CCI,100);

        TJ91:=WLT95ANDWLT96;

        JLP:=FILTER(TJ91,5);

        超买:=MA(C,10)*IF(CAPITAL=0,1.04,1.1);

        超卖:=MA(C,10)*IF(CAPITAL=0,0.95,0.9);

        TEND:=EMA(((SLOPE(CLOSE,21)*20)+CLOSE),42);

        DD:=TEND REF(TEND,1)ANDREF(TEND,1) REF(TEND,2);

        GG2:=CROSS(WLT1,TEND);

        HRY1:=LLV(LOW,55);

        HRY2:=HHV(HIGH,21);

        GG3:=C HRY2*0.8ANDC HRY33;

        JJ1:=C HRY1*1.62;

        TJ1:=GG1;

        TJ2:=GG2ANDJJ1;

        TJ3:=GG1ANDGG3;

        XG:=TJ1ORTJ3;

        XG2:=C HRY2*0.86ORLB

        XG1:=XGANDXG2ANDC HRY33ANDJLP;

        XG3:=XGANDC HHV(HIGH,250)*0.3;

        XG11:=XG1ORXG3;

        FILTER(BB5 1ANDEMA(X1,7) REF(EMA(X1,7),1),10)ANDXG1;




    九毛八公式指标,一个优质的公式指标平台!
    九毛八公式指标 » 主力仓位指标公式(股票主力仓位指标公式) 加入收藏