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

    正文概述    2024-05-04 04:24:19  


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


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


    授权方式: 免费版


    指标评级: ★★★★★


    指标分类: 策略


    画线方法: 副图



    一、状态五色指标公式

     

    CN1:=HHV(V,5);CN2:=O CN02:=C CN03:=C=O; 

    CN04:=((SUM(V,5)/CN1));CN05:=IF(CN04 0.3,1,0); 

    CN06:=IF(CN2ANDCN05,V,0);CN07:=IF(CN02ANDCN05,V,0); 

    CN08:=IF(CN03ANDCN05,V,0); 

    AD:SUM(CN07,3),coloryellow;DA:=SUM(CN06,3); 

    AZ:(AD-DA),COLOR0000FF;AF:=AZ=AD; 

    FS:0,colorgray; 

    JJ:=(HIGH+LOW+CLOSE)/3;QJ0:=AMOUNT/IF(HIGH=LOW,4,HIGH-LOW); 

    买1:=QJ0*(MIN(OPEN,CLOSE)-LOW); 

    买2:=QJ0*(JJ-MIN(CLOSE,OPEN)); 

    卖1:=QJ0*(MAX(CLOSE,OPEN)-JJ); 

    卖2:=QJ0*(HIGH-MAX(OPEN,CLOSE)); 

    DT:=((买1+买2)-(卖1+卖2))/10000,NODRAW; 

    主力增:DT,NODRAW; 

    主力持仓线:SUM(DT,66),COLORRED,LINETHICK1; 

    TD1:=QJ0*(MIN(OPEN,CLOSE)-LOW);DD1:=QJ0*(JJ-MIN(CLOSE,OPEN)); 

    DD2:=QJ0*(HIGH-MAX(OPEN,CLOSE));TD2:=QJ0*(MAX(CLOSE,OPEN)-JJ); 

    TD:=TD1-TD2;DA:=DD1-DD2;XD1:=1-(TD1+DD1);XD2:=1-(TD2+DD2); 

    换手:VOL/CAPITAL*100,NODRAW; 

    十日换手:SUM(换手,10),NODRAW; 

    STICKLINE(C,0,换手,2,0),COLOR408080; 

    累计:SUM(换手,10),LINESTICK; 

    STICKLINE(换手 5,5,换手,2,0),COLORRED; 

    STICKLINE(换手 17,17,换手,2,0),COLORGREEN; 

    过5反红:0,NODRAW,COLOR00FFFF; 

    低位绿进货:0,NODRAW,COLOR0000FF; 

    高位绿庄家出货:0,NODRAW,COLOR00FF80; 

    TZ:=V/SUM(V,60)*100;DDT:=((XD1-XD2)/10000)/TZ; 

    增:DDT,NODRAW; 

    散户持仓线:SUM(DDT,22),COLORGREEN,LINETHICK1; 

    主力比散户:DT/ABS(DDT),NODRAW,COLORMAGENTA; 

    主力比散户线:MA(DT/ABS(DDT)*1000,3),COLORBLUE,LINETHICK1; 

    V1:=DMA((((HIGH+LOW)+(CLOSE*2))/4),0.9); 

    HY1:=REF(EMA(V1,3),1); 

    多空:=(MA((CLOSE-HY1)*10,2))*0.1; 

    操盘4:STICKLINE(多空趋势 =0AND多空趋势 =REF(多空趋势,1),6.5,6.5+多空趋势,1.5,0),COLORRED; 

    减仓4:STICKLINE(多空趋势 =0AND多空趋势 REF(多空趋势,1),6.5,6.5+多空趋势,1.5,0),COLORRED; 

    反弹4:STICKLINE(多空趋势 0AND多空趋势 =REF(多空趋势,1),6.5,6.5+多空趋势,1.5,0),COLORGREEN; 

    寻底4:STICKLINE(多空趋势 0AND多空趋势 REF(多空趋势,1),6.5,6.5+多空趋势,1.5,0),COLORGREEN; 

    DRAWTEXT(ISLASTBAR=1,IF(多空趋势 =0,6,6.3), 多空 ),COLORWHITE; 

    换手:=V*100/CAPITAL; 

    主力:=MA(换手,4); 

    大户:=MA(换手,9); 

    中户:=MA(换手,17); 

    散户:=MA(换手,34); 

    均量:=(主力+大户+中户+散户)/4; 

    :V,COLORWHITE,NODRAW; 

    主力能量:(主力-均量)COLORMAGENTA,NODRAW; 

    大户能量:(大户-均量)COLORYELLOW,NODRAW; 

    中户能量:(中户-均量)COLORLIBLUE,NODRAW; 

    散户能量:(散户-均量)COLORBLUE,NODRAW; 

    操盘:STICKLINE(主力能量 =0AND主力能量 =REF(主力能量,1),4.5,4.5+主力能量,1.5,0),COLORYELLOW; 

    减仓:STICKLINE(主力能量 =0AND主力能量 REF(主力能量,1),4.5,4.5+主力能量,1.5,0),COLORRED; 

    反弹:STICKLINE(主力能量 0AND主力能量 =REF(主力能量,1),4.5,4.5+主力能量,1.5,0),COLORGREEN; 

    寻底:STICKLINE(主力能量 0AND主力能量 REF(主力能量,1),4.5,4.5+主力能量,1.5,0),COLORGREEN; 

    DRAWTEXT(ISLASTBAR=1,IF(主力能量 =0,4.2,4.8), ),COLORMAGENTA; 

    操盘1:STICKLINE(大户能量 =0AND大户能量 =REF(大户能量,1),3,3+大户能量,1.5,0),COLORWHITE; 

    减仓1:STICKLINE(大户能量 =0AND大户能量 REF(大户能量,1),3,3+大户能量,1.5,0),COLORRED; 

    反弹1:STICKLINE(大户能量 0AND大户能量 =REF(大户能量,1),3,3+大户能量,1.5,0),COLORGREEN; 

    寻底1:STICKLINE(大户能量 0AND大户能量 REF(大户能量,1),3,3+大户能量,1.5,0),COLORGREEN; 

    DRAWTEXT(ISLASTBAR=1,IF(大户能量 =0,2.7,3.3), 大户 ),COLORYELLOW; 

    操盘2:STICKLINE(中户能量 =0AND中户能量 =REF(中户能量,1),1.5,1.5+中户能量,1.5,0),COLORRED; 

    减仓2:STICKLINE(中户能量 =0AND中户能量 REF(中户能量,1),1.5,1.5+中户能量,1.5,0),COLORRED; 

    反弹2:STICKLINE(中户能量 0AND中户能量 =REF(中户能量,1),1.5,1.5+中户能量,1.5,0),COLORGREEN; 

    寻底2:STICKLINE(中户能量 0AND中户能量 REF(中户能量,1),1.5,1.5+中户能量,1.5,0),COLORGREEN; 

    ZLCM:=EMA(WINNER(CLOSE)*70,3);{//主力估算} 

    SHCM:=EMA((WINNER(CLOSE*1.1)-WINNER(CLOSE*0.9))*80,3);{//散户筹码估算} 

    ZSHTL:=SHCM/(ZLCM+SHCM)*100;{//散户套牢筹码比率} 

    ZZLKP:=ZLCM/(ZLCM+SHCM)*100;{//主力控盘筹码比率} 

    ZCMZL:=MA(ZLCM+SHCM,13);{//市场筹码总量} 

    ZZNTS:=BARSLAST(ZSHTL 90ANDREF(ZSHTL,1) {//走牛天数} 

    ZSHJJ:=EMA(ZSHTL,89);{//散户警戒} 

    ZZLJJ:=EMA(ZZLKP,89);{//主力警戒} 

    ZJLRQD:=INTPART(ZZLKP-ZZLJJ);{//流入强度} 

    SH8:=EMA(ZSHTL,8); 

    DKB:=IF(ZZLKP-REF(ZZLKP,1) ZSHTL-REF(ZSHTL,1),1,0); 

    {散户套牢筹码} 

    STICKLINE(C 0,ZSHTL,ZZLKP,1,0),COLORFFFFFF; 

    {散户筹码警戒} 

    STICKLINE(ZSHJJ REF(ZSHJJ,1),ZSHTL,ZSHJJ,2,0),COLOR00FF00; 

    {主力控盘筹码} 

    STICKLINE(C 0,ZZLKP,0,1,0),COLORA4A4A4; 

    {筑顶风险区} 

    STICKLINE(ZZLKP 75,ZZLKP,0,1,0),COLORFFFFFF; 

    {顶部:(ZZLKP 75),COLORFFFFFF;} 

    {主力筹码警戒} 

    STICKLINE(ZZLJJ REF(ZZLJJ,1),ZZLKP,ZZLJJ,2,0),COLORRED; 

    {筑底散兵坑} 

    {底部:(ZSHTL =90),COLOR66FFCC;} 

    {筹码总量上升} 

    IF(ZCMZL,ZCMZL REF(ZCMZL,1),DRAWNULL),COLOR0066FF,LINETHICK1; 

    {增量资金}; 

    {//------【数值显示】} 

    散户套牢系数:INTPART(ZSHTL),COLORCYAN,LINETHICK2; 

    主力控盘系数:INTPART(ZZLKP),COLORYELLOW,LINETHICK2; 

    资金流入强度:ZJLRQD,LINETHICK2,COLORRED; 

    资金流入强度2:IF(ZJLRQD 10,ZJLRQD,DRAWNULL),LINETHICK2,COLORWHITE; 

    市场筹码总量:INTPART(ZCMZL),COLORWHITE,NODRAW; 

    DRAWICON(CROSS(主力控盘系数,散户套牢系数),散户套牢系数-5,11); 

    DRAWICON(CROSS(资金流入强度,散户套牢系数),散户套牢系数-5,17); 

    DRAWTEXT(ISLASTBAR=1,IF(中户能量 =0,1.2,1.8), 中户 ),COLORLIBLUE; 

    操盘3:STICKLINE(散户能量 =0AND散户能量 =REF(散户能量,1),0,散户能量,1.5,0),COLORRED; 

    减仓3:STICKLINE(散户能量 =0AND散户能量 REF(散户能量,1),0,散户能量,1.5,0),COLORRED; 

    反弹3:STICKLINE(散户能量 0AND散户能量 =REF(散户能量,1),0,散户能量,1.5,0),COLORGREEN; 

    寻底3:STICKLINE(散户能量 0AND散户能量 REF(散户能量,1),0,散户能量,1.5,0),COLORGREEN; 

    DRAWTEXT(ISLASTBAR=1,IF(散户能量 =0,-0.3,0.3), 散户 ),COLORBLUE; 

    JZ:=V/(ABS(主力能量)+ABS(大户能量)+ABS(中户能量)+ABS(散户能量)); 

    ZLCJ:=JZ*ABS(主力能量); 

    DHCJ:=JZ*ABS(大户能量); 

    ZHCJ:=JZ*ABS(中户能量); 

    SHCJ:=JZ*ABS(散户能量); 

    机构量:ZLCJ,COLORMAGENTA,NODRAW; 

    大户量:DHCJ,COLORYELLOW,NODRAW; 

    中户量:ZHCJ,COLORLIBLUE,NODRAW; 

    散户量:SHCJ,COLORBLUE,NODRAW;

    公式解读:



    二、五彩主力进出指标公式


     

    主流资金:EMA(100*(C-LLV(LOW,34))/(HHV(H,34)-LLV(LOW,34)),3),COLORRED,LINETHICK2; 

    非主流资金:EMA(100*(INDEXC-LLV(INDEXL,34))/(HHV(INDEXH,34)-LLV(INDEXL,34)),3),COLORGREEN,LINETHICK2; 

    20,POINTDOT,COLORF00FF0; 

    50,POINTDOT,COLORGREEN; 

    80,POINTDOT,COLORWHITE; 

    DIFF:EMA(CLOSE,3)-EMA(CLOSE,26),colorwhite; 

    DEA:EMA(DIFF,9),coloryellow; 

    MACD:2*(DIFF-DEA); 

    ZERO:0; 

    DRAWICON(CROSS(DIFF,DEA),DEA*1.02,1); 

    DRAWICON(CROSS(DEA,DIFF),DEA*0.98,2); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF REF(DIFF,1)ANDDEA REF(DEA,1),colorlired); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF =REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF =REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF REF(DIFF,1)ANDDEA REF(DEA,1),colorred); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF =REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF =REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF REF(DIFF,1)ANDDEA REF(DEA,1),colorgreen); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF =REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF =REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF REF(DIFF,1)ANDDEA REF(DEA,1),colorblue); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF =REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    FILLRGN(DIFF,DEA,DIFF DEAANDDIFF 0ANDDIFF =REF(DIFF,1)ANDDEA REF(DEA,1),colorwhite); 

    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)ANDMA(CLOSE,10) MA(CLOSE,30)ANDMA(CLOSE,30) MA(CLOSE,60); 

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

    多头成交:STICKLINE(CLOSE MA(CLOSE,30),0,VOL,2.5,1),,COLORRED; 

    空头成交:STICKLINE(CLOSE MA(CLOSE,30),0,VOL,2.5,1),,COLORGREEN; 

    向上攻击量:STICKLINE(VAR6 =VAR7ANDVAR6 =VAR8ANDCLOSE OPEN,0,VAR6,2.5,0),,COLORRED; 

    向下攻击量:STICKLINE(VAR6 =VAR7ANDVAR6 =VAR8ANDCLOSE OPEN,0,VAR6,2.5,0),,COLORGREEN; 

    上探量:STICKLINE(VAR7 VAR6ANDVAR7 VAR8,0,VAR7,2.5,0),,COLORCCCC66; 

    下探量:STICKLINE(VAR8 VAR6ANDVAR8 VAR7,0,VAR8,2.5,0),,COLORFF6633; 

    相对地量:STICKLINE(VAR9 2ANDVOL MA(VOL,5)/2,0,VOL,2.5,0),,COLORYELLOW; 

    地量:DRAWTEXT(VAR9 2ANDVOL MA(VOL,5)/2,VOL, 地量 ),,COLORYELLOW; 

    放量:STICKLINE(VOL MA(VOL,5)*2.5,0,VOL,2.5,0),,COLORWHITE; 

    逢高出货:DRAWTEXT(VAR7 VAR6ANDVARA 2ANDVAR7 VAR8ANDCLOSE MA(CLOSE,5)ANDCLOSE MA(CLOSE,30)ANDHIGH MA(CLOSE,60)ANDVOL MA(VOL,5)ANDVAR7 =MA(VOL,5),VOL, 逢高出货 ),,COLORGREEN; 

    逢低跟进:DRAWTEXT(VAR8 VAR6ANDVAR8 VAR7ANDVARA -2ANDCLOSE MA(CLOSE,30)ANDVAR8 MA(VOL,5)/2ANDMA(VOL,5) MA(VOL,10),VOL, 逢低跟进 ),,COLORWHITE; 

    强势参与:DRAWTEXT(VAR6 MA(VOL,5)*2ANDVAR6 =VAR7ANDVAR6 =VAR8ANDCLOSE OPENORVOL MA(VOL,5)*3ANDVARB,VOL, 强势参与 ),,COLORCC99CC; 

    空头释放:DRAWTEXT(VAR6 =VAR7ANDVAR6 =VAR8ANDCLOSE OPENANDVAR6/VOL 0.7ANDVARCANDVAR6 MA(VOL,5),VAR6*2, 空头释放 ),,COLORGREEN; 

    {MA5:MA(VOL,5),,COLORRED; 

    MA10:MA(VOL,10),,COLORGREEN; 

    MA20:MA(VOL,20),,COLORYELLOW;} 

    MA5:MA(VOL,5),COLORYELLOW; 

    MA13:MA(VOL,13),COLORWHITE; 

    DRAWTEXT(CROSS(MA5,MA13),CROSS(MA5,MA13), 注意 ),COLORWHITE; 

    STICKLINE(C,90,90,0.9,0.9),COLOR883333; 

    STICKLINE(C,10,10,0.9,0.9),COLOR883333; 

    散户:=100*(HHV(HIGH,60)-CLOSE)/(HHV(HIGH,60)-LLV(LOW,60)); 

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

    RSV1:=(C-MA(C,4))/MA(C,4)*100; 

    VAR2:=REF(LOW,1); 

    VAR3:=SMA(ABS(LOW-VAR2),3,1)/SMA(MAX(LOW-VAR2,0),3,1)*100; 

    VAR4:=EMA(IF(CLOSE*1.3,VAR3*10,VAR3/10),3); 

    VAR5:=LLV(LOW,30); 

    VAR6:=HHV(VAR4,30); 

    VAR7:=IF(MA(CLOSE,58),1,0); 

    VAR8:=EMA(IF(LOW =VAR5,(VAR4+VAR6*2)/2,0),3)/618*VAR7; 

    VAR9:=IF(VAR8 100,100,VAR8); 

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

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

    J:=3*K-2*D; 

    主力:=EMA(J,6),COLORYELLOW; 

    AA3:=(HHV(HIGH,21)-CLOSE)/(HHV(HIGH,21)-LLV(LOW,21))*100-10; 

    AA4:=(CLOSE-LLV(LOW,21))/(HHV(HIGH,21)-LLV(LOW,21))*100; 

    AA5:=SMA(AA4,13,8); 

    走势:=CEILING(SMA(AA5,13,8)),COLORRED,LINETHICK2; 

    AA6:=SMA(AA3,21,8); 

    买观注:STICKLINE(走势-AA6 -65,0,7,15,1); 

    DRAWICON(FILTER(J REF(J,1)AND走势 =REF(走势,1)AND走势 25,5),走势,1); 

    卖观注:STICKLINE(走势-AA6 85,98,90,15,1),COLORFFFF00; 

    DRAWICON(FILTER(J REF(J,1)AND走势 =REF(走势,1)ANDJ 85,5),J,2); 

    吸筹:STICKLINE(VAR9 -120,50,50+(VAR9/2),8,1),COLORRED; 

    CDMA:EMA(EMA(RSV1,7),7)*8,NODRAW,COLORWHITE; 

    STICKLINE(CDMA =0ANDCDMA =REF(CDMA,1),50,50+CDMA,2.5,0),COLORDD55CC; 

    STICKLINE(CDMA =0ANDCDMA =REF(CDMA,1),50,50+CDMA,2.5,1),COLORDD55CC; 

    STICKLINE(CDMA =0ANDCDMA =REF(CDMA,1),50,50+CDMA,2.5,1),COLOR00D080; 

    STICKLINE(CDMA =0ANDCDMA =REF(CDMA,1),50,50+CDMA,2.5,0),COLOR00D080; 

    快线:(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100,LINETHICK2,COLOR333333; 

    散户线:散户,COLORFFFFFF,LINETHICK1; 

    主力线:主力,COLORYELLOW; 

    走势线:走势,COLORRED,LINETHICK3; 

    DRAWTEXT(ISLASTBAR,散户线, ←散户线 ),COLORFFFFFF; 

    DRAWTEXT(ISLASTBAR,主力线, ←主力线 ),COLORYELLOW; 

    DRAWTEXT(ISLASTBAR,走势线, ←走势线 ),COLORRED; 

    关注低买:IF(90 散户ANDCROSS(90,散户),98,0),COLORMAGENTA,STICK,NODRAW; 

    {高抛低吸:IF(散户 10ANDCROSS(10,散户),20,0),COLORGREEN,STICK,NODRAW;} 

    风险:COUNT( RSI.RSI1 (6,12,24) 80,3)=3ANDCROSS( RSI.RSI2 (6,12,24),79.5),NODRAW; 

    观注顶:(散户 8AND主力 90AND走势 90ANDCDMA =REF(CDMA,1)AND散户线),COLORGREEN,NODRAW; 

    DRAWTEXT(观注顶,-1, ◆ ),COLORGREEN; 

    DRAWTEXT(风险,95, ←风险 ),COLOR00FFFF; 

    STICKLINE(关注低买,0,100,0,-1),COLORMAGENTA; 

    {STICKLINE(高抛低吸,0,100,0,-1),COLORGREEN;};


    image.png


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


    TJ1赋值:收盘价和开盘价的较小值/最低价 1.015

    TJ2赋值:(收盘价和开盘价的较小值-最低价) (最高价-收盘价和开盘价的较大值)

    TJ赋值:TJ1 AND TJ2

    TJ3赋值:最低价和1日前的最低价的较大值/最低价和1日前的最低价的较小值 1.004

    TJ4赋值:收盘价和开盘价的较大值/收盘价和开盘价的较小值 收盘价和开盘价的较小值/最低价

    最近2日一直存在TJANDTJ4 AND TJ3



    推荐阅读:主力状态三色指标

     

    N1:=6;N2:=12;N3:=24; 

    LC:=REF(CLOSE,1); 

    RSI1:=SMA(MAX(CLOSE-LC,0),N1,1)/SMA(ABS(CLOSE-LC),N1,1)*100; 

    RSI2:=SMA(MAX(CLOSE-LC,0),N2,1)/SMA(ABS(CLOSE-LC),N2,1)*100; 

    RSI3:=SMA(MAX(CLOSE-LC,0),N3,1)/SMA(ABS(CLOSE-LC),N3,1)*100; 

    STICKLINE(C,90,90,0.9,0.9),COLOR883333; 

    STICKLINE(C,10,10,0.9,0.9),COLOR883333; 

    散户:=100*(HHV(HIGH,60)-CLOSE)/(HHV(HIGH,60)-LLV(LOW,60)); 

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

    RSV1:=(C-MA(C,4))/MA(C,4)*100; 

    VAR2:=REF(LOW,1); 

    VAR3:=SMA(ABS(LOW-VAR2),3,1)/SMA(MAX(LOW-VAR2,0),3,1)*100; 

    VAR4:=EMA(IF(CLOSE*1.3,VAR3*10,VAR3/10),3); 

    VAR5:=LLV(LOW,30); 

    VAR6:=HHV(VAR4,30); 

    VAR7:=IF(MA(CLOSE,58),1,0); 

    VAR8:=EMA(IF(LOW =VAR5,(VAR4+VAR6*2)/2,0),3)/618*VAR7; 

    VAR9:=IF(VAR8 100,100,VAR8); 

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

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

    J:=3*K-2*D; 

    主力:=EMA(J,6),COLORYELLOW; 

    AA3:=(HHV(HIGH,21)-CLOSE)/(HHV(HIGH,21)-LLV(LOW,21))*100-10; 

    AA4:=(CLOSE-LLV(LOW,21))/(HHV(HIGH,21)-LLV(LOW,21))*100; 

    AA5:=SMA(AA4,13,8); 

    走势:=CEILING(SMA(AA5,13,8)),COLORRED,LINETHICK2; 

    AA6:=SMA(AA3,21,8); 

    DRAWICON(FILTER(J REF(J,1)AND走势 =REF(走势,1)AND走势 25,5),0.1*走势,1); 

    STICKLINE(走势-AA6 85,98,90,5,1),COLORFFFF00; 

    STICKLINE(VAR9 -120,50,50+(VAR9/2),8,1),COLORRED; 

    CDMA:EMA(EMA(RSV1,7),7)*8,LINETHICK0,COLORWHITE; 

    STICKLINE(CDMA =0ANDCDMA =REF(CDMA,1),50,50+CDMA,2.5,0),COLORDD55CC; 

    STICKLINE(CDMA =0ANDCDMA =REF(CDMA,1),50,50+CDMA,2.5,1),COLORDD55CC; 

    STICKLINE(CDMA =0ANDCDMA =REF(CDMA,1),50,50+CDMA,2.5,1),COLOR00D080; 

    STICKLINE(CDMA =0ANDCDMA =REF(CDMA,1),50,50+CDMA,2.5,0),COLOR00D080; 

    快线:(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100,LINETHICK1,COLORGREEN; 

    散户线:散户,COLORFFFFFF,LINETHICK1; 

    主力线:主力,COLORYELLOW; 

    走势线:走势,COLORRED,LINETHICK1; 

    {散户线主力线} 

    强:90,COLORCYAN,LINETHICK3,POINTDOT; 

    弱:10,LINETHICK3,POINTDOT; 

    界线:50,COLORA8A8A8,POINTDOT,LINETHICK4; 

    {主力吸筹} 

    VAR2:=REF(LOW,1); 

    VAR3:=SMA(ABS(LOW-VAR2),3,1)/SMA(MAX(LOW-VAR2,0),3,1)*100; 

    VAR4:=EMA(IF(CLOSE*1.3,VAR3*10,VAR3/10),3); 

    VAR5:=LLV(LOW,30); 

    VAR6:=HHV(VAR4,30); 

    VAR7:=IF(MA(CLOSE,58),1,0); 

    VAR8:=EMA(IF(LOW =VAR5,(VAR4+VAR6*2)/2,0),3)/618*VAR7; 

    VAR9:=IF(VAR8 100,100,VAR8); 

    吸筹:STICKLINE(VAR9 -120,0,VAR9,2,5),COLORMAGENTA; 

    {地量买点} 

    地量:DRAWTEXT(CROSS(0.9,1/VOL*1000 0.01AND KDJ.J 0),L*1, 地量 ),COLOR00FFFF; 

    STICKLINE(地量 0,0,30,2,0),COLOR008888; 

    STICKLINE(地量 0,0,30,1.5,0),COLOR00AAAA; 

    STICKLINE(地量 0,0,30,0.8,0),COLOR00DDDD; 

    STICKLINE(地量 0,0,30,0.3,0),COLOR00FFFF; 

    {成交%} 

    AA:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN)); 

    主买:=IF(CLOSE OPEN,AA*(HIGH-LOW),IF(CLOSE OPEN,AA*((HIGH-OPEN)+(CLOSE-LOW)),VOL/2)); 

    量比%:主买/VOL*100,LINETHICK4,LINETHICK0; 

    {主力资金流量} 

    主持仓:EMA(100*(CLOSE-LLV(LOW,34))/(HHV(HIGH,34)-LLV(LOW,34)),3),LINETHICK0; 

    主筹码:WINNER(C)*100,LINETHICK0; 

    {有大资金进场迹象,关注!} 

    VAR10:=100-3*SMA((CLOSE-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1)+2*SMA(SMA((CLOSE-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1),15,1); 

    VAR11:=100-3*SMA((OPEN-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1)+2*SMA(SMA((OPEN-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1),15,1); 

    VAR12:=VAR10 REF(VAR11,1)ANDVOL REF(VOL,1)ANDCLOSE REF(CLOSE,1); 

    DRAWTEXT(VAR12ANDCOUNT(VAR12,30)=1,40, 有大资金进场迹象,关注!  

    {散户线主力线走势线} 

    AA4:=(CLOSE-LLV(LOW,21))/(HHV(HIGH,21)-LLV(LOW,21))*100; 

    AA5:=SMA(AA4,13,8); 

    走势:CEILING(SMA(AA5,13,8)),COLORRED,LINETHICK2; 

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

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

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

    J:=3*K-2*D; 

    主力线:EMA(J,6),COLORYELLOW,LINETHICK2; 

    散户线:100*(HHV(HIGH,60)-CLOSE)/(HHV(HIGH,60)-LLV(LOW,60)),COLORGREEN; 

    {逃人} 

    VARR1:=SMA(MAX(CLOSE-REF(C,1),0),6,1)/SMA(ABS(CLOSE-REF(C,1)),6,1)*100; 

    DRAWICON(CROSS(82,VARR1),10,15); 

    关注低买:IF(90 散户ANDCROSS(90,散户),98,0),COLORMAGENTA,STICK,LINETHICK0; 

    {高抛低吸:IF(散户 10ANDCROSS(10,散户),20,0),COLORGREEN,STICK,NODRAW;} 

    风险:COUNT(RSI1 80,3)=3ANDCROSS(RSI2,79.5),LINETHICK0; 

    观注顶:(散户 8AND主力 90AND走势 90ANDCDMA =REF(CDMA,1)AND散户线),COLORGREEN,LINETHICK0; 

    DRAWTEXT(观注顶,-1, ◆ ),COLORGREEN; 

    DRAWTEXT(风险,95, ←风险 ),COLOR00FFFF; 

    STICKLINE(关注低买,0,100,0,-1),COLORMAGENTA; 

    {STICKLINE(高抛低吸,0,100,0,-1),COLORGREEN;}; 

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

    a=HIGH-LOW; 

    IF(HIGH==LOW)a=0.01; 

    Var2:=SUM(((Var1-REF(LOW,1))-(HIGH-Var1))*VOL/10000000/a,0); 

    Var3:=EMA(Var2,1); 

    JCS:Var3; 

    JCM:MA(Var3,12); 

    JCL:MA(Var3,26); 

    a:var2; 

    QB:=(H-L); 

    SY:=(H-MAX(C,O))/QB*100/100; 

    ST:=(MAX(C,O)-MIN(C,O))/QB*100/100; 

    XY:=(MIN(C,O)-L)/QB*100/100; 

    STICKLINE((C OOR(C=OANDC =REF(C,1)))ANDL!=O,0,VOL*XY,2,0),COLORYELLOW; 

    STICKLINE(C OOR(C=OANDC =REF(C,1)),VOL*XY,VOL*XY+VOL*ST,2,0),COLORRED; 

    STICKLINE((C OOR(C=OANDC =REF(C,1)))ANDH!=C,VOL*ST+VOL*XY,VOL,2,0),COLORGREEN; 

    STICKLINE((C OOR(C=OANDC REF(C,1)))ANDL!=C,0,VOL*XY,2,0),COLORYELLOW; 

    STICKLINE(C OOR(C=OANDC REF(C,1)),VOL*XY,VOL*XY+VOL*ST,2,0),COLORCYAN; 

    STICKLINE((C OOR(C=OANDC REF(C,1)))ANDH!=O,VOL*ST+VOL*XY,VOL,2,0),COLORGREEN;


    image.png


    每日公式解答:

     

    公式编写要求: 

    百日最高量的公式。 

    公式编写方法: 

    XG:HHVBARS(H,100)=0;


    九毛八公式指标,一个优质的公式指标平台!
    九毛八公式指标 » 主力状态五色指标公式(五彩主力进出指标公式) 加入收藏