通达信金坑迎财神主图指标公式

[复制链接]
查看113 | 回复0 | 2021-8-20 12:05:24 | 显示全部楼层 |阅读模式

X_1:=120;
X_2:=COST(0.33);
X_3:=COST(5);
X_4:=COST(15);
X_5:=COST(55);
X_6:=COST(97);
X_7:=COST(90);
X_8:=COST(70);
X_9:=COST(30);
X_10:=COST(10);
X_11:=CONST(HHV(X_6,120));
X_12:=CONST(LLV(X_7,120));
X_13:=40;
X_14:=(X_11-X_12)/X_13;
X_15:=1000;
X_16:=ROUND(COUNT(RANGE(CLOSE,X_12+10,X_12+11*X_14),X_1)/X_1*X_15);
X_17:=ROUND(COUNT(RANGE(CLOSE,X_12+11*X_14,X_12+12*X_14),X_1)/X_1*X_15);
X_18:=ROUND(COUNT(RANGE(CLOSE,X_12+12*X_14,X_12+13*X_14),X_1)/X_1*X_15);
X_19:=ROUND(COUNT(RANGE(CLOSE,X_12+13*X_14,X_12+14*X_14),X_1)/X_1*X_15);
X_20:=ROUND(COUNT(RANGE(CLOSE,X_12+14*X_14,X_12+15*X_14),X_1)/X_1*X_15);
X_21:=ROUND(COUNT(RANGE(CLOSE,X_12+15*X_14,X_12+16*X_14),X_1)/X_1*X_15);
X_22:=ROUND(COUNT(RANGE(CLOSE,X_12+16*X_14,X_12+17*X_14),X_1)/X_1*X_15);
X_23:=ROUND(COUNT(RANGE(CLOSE,X_12+17*X_14,X_12+18*X_14),X_1)/X_1*X_15);
X_24:=ROUND(COUNT(RANGE(CLOSE,X_12+18*X_14,X_12+19*X_14),X_1)/X_1*X_15);
X_25:=ROUND(COUNT(RANGE(CLOSE,X_12+19*X_14,X_12+20*X_14),X_1)/X_1*X_15);
X_26:=ROUND(COUNT(RANGE(CLOSE,X_12+20*X_14,X_12+21*X_14),X_1)/X_1*X_15);
X_27:=ROUND(COUNT(RANGE(CLOSE,X_12+21*X_14,X_12+22*X_14),X_1)/X_1*X_15);
X_28:=ROUND(COUNT(RANGE(CLOSE,X_12+22*X_14,X_12+23*X_14),X_1)/X_1*X_15);
X_29:=ROUND(COUNT(RANGE(CLOSE,X_12+23*X_14,X_12+24*X_14),X_1)/X_1*X_15);
X_30:=ROUND(COUNT(RANGE(CLOSE,X_12+24*X_14,X_12+25*X_14),X_1)/X_1*X_15);
X_31:=ROUND(COUNT(RANGE(CLOSE,X_12+25*X_14,X_12+26*X_14),X_1)/X_1*X_15);
X_32:=ROUND(COUNT(RANGE(CLOSE,X_12+26*X_14,X_12+27*X_14),X_1)/X_1*X_15);
X_33:=ROUND(COUNT(RANGE(CLOSE,X_12+27*X_14,X_12+28*X_14),X_1)/X_1*X_15);
X_34:=ROUND(COUNT(RANGE(CLOSE,X_12+28*X_14,X_12+29*X_14),X_1)/X_1*X_15);
X_35:=ROUND(COUNT(RANGE(CLOSE,X_12+29*X_14,X_12+30*X_14),X_1)/X_1*X_15);
X_36:=ROUND(COUNT(RANGE(CLOSE,X_12+30,X_12+31*X_14),X_1)/X_1*X_15);
X_37:=ROUND(COUNT(RANGE(CLOSE,X_12+31*X_14,X_12+32*X_14),X_1)/X_1*X_15);
X_38:=ROUND(COUNT(RANGE(CLOSE,X_12+32*X_14,X_12+33*X_14),X_1)/X_1*X_15);
X_39:=ROUND(COUNT(RANGE(CLOSE,X_12+33*X_14,X_12+34*X_14),X_1)/X_1*X_15);
X_40:=ROUND(COUNT(RANGE(CLOSE,X_12+34*X_14,X_12+35*X_14),X_1)/X_1*X_15);
X_41:=ROUND(COUNT(RANGE(CLOSE,X_12+35*X_14,X_12+36*X_14),X_1)/X_1*X_15);
X_42:=ROUND(COUNT(RANGE(CLOSE,X_12+36*X_14,X_12+37*X_14),X_1)/X_1*X_15);
X_43:=ROUND(COUNT(RANGE(CLOSE,X_12+37*X_14,X_12+38*X_14),X_1)/X_1*X_15);
X_44:=ROUND(COUNT(RANGE(CLOSE,X_12+38*X_14,X_12+39*X_14),X_1)/X_1*X_15);
X_45:=ROUND(COUNT(RANGE(CLOSE,X_12+39*X_14,X_12+40*X_14),X_1)/X_1*X_15);
STICKLINE(CURRBARSCOUNT<=X_16,X_12+10.3*X_14,X_12+10.7*X_14,0.7,0),COLOR0000AA;
STICKLINE(CURRBARSCOUNT<=X_17,X_12+11.3*X_14,X_12+11.7*X_14,0.8,0),COLOR0000AA;
STICKLINE(CURRBARSCOUNT<=X_18,X_12+12.3*X_14,X_12+12.7*X_14,0.9,0),COLOR0000AA;
STICKLINE(CURRBARSCOUNT<=X_19,X_12+13.3*X_14,X_12+13.7*X_14,1,0),COLOR0000AA;
STICKLINE(CURRBARSCOUNT<=X_20,X_12+14.3*X_14,X_12+14.7*X_14,1.2,0),COLOR0000AA;
STICKLINE(CURRBARSCOUNT<=X_21,X_12+15.3*X_14,X_12+15.7*X_14,1.6,0),COLOR0000AA;
STICKLINE(CURRBARSCOUNT<=X_22,X_12+16.299999*X_14,X_12+16.700001*X_14,1.8,0),COLOR0000AA;
STICKLINE(CURRBARSCOUNT<=X_23,X_12+17.299999*X_14,X_12+17.700001*X_14,2,0),COLOR0000AA;
STICKLINE(CURRBARSCOUNT<=X_24,X_12+18.299999*X_14,X_12+18.700001*X_14,2.1,0),COLOR0000AA;
STICKLINE(CURRBARSCOUNT<=X_25,X_12+19.299999*X_14,X_12+19.700001*X_14,2.2,0),COLOR0000AA;
STICKLINE(CURRBARSCOUNT<=X_26,X_12+20.299999*X_14,X_12+20.700001*X_14,2.3,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_27,X_12+21.299999*X_14,X_12+21.700001*X_14,2.4,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_28,X_12+22.299999*X_14,X_12+22.700001*X_14,2.5,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_29,X_12+23.299999*X_14,X_12+23.700001*X_14,2.6,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_30,X_12+24.299999*X_14,X_12+24.700001*X_14,2.7,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_31,X_12+25.299999*X_14,X_12+25.700001*X_14,2.8,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_32,X_12+26.299999*X_14,X_12+26.700001*X_14,2.9,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_33,X_12+27.299999*X_14,X_12+27.700001*X_14,3,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_34,X_12+28.299999*X_14,X_12+28.700001*X_14,3.1,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_35,X_12+29.299999*X_14,X_12+29.700001*X_14,3.2,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_36,X_12+30.299999*X_14,X_12+30.700001*X_14,3.3,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_37,X_12+31.299999*X_14,X_12+31.700001*X_14,3.4,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_38,X_12+32.299999*X_14,X_12+32.700001*X_14,3.5,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_39,X_12+33.299999*X_14,X_12+33.700001*X_14,3.6,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_41,X_12+35.299999*X_14,X_12+35.700001*X_14,3.7,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_42,X_12+36.299999*X_14,X_12+36.700001*X_14,3.8,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_43,X_12+37.299999*X_14,X_12+37.700001*X_14,3.9,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_44,X_12+38.299999*X_14,X_12+38.700001*X_14,4,0),COLOREAEAEA;
STICKLINE(CURRBARSCOUNT<=X_45,X_12+39.299999*X_14,X_12+39.700001*X_14,4,0),COLOREAEAEA;
X_46:=ROUND(SUM(IF(RANGE(CLOSE,X_12+10*X_14,X_12+11*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_47:=ROUND(SUM(IF(RANGE(CLOSE,X_12+12*X_14,X_12+13*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_48:=ROUND(SUM(IF(RANGE(CLOSE,X_12+14*X_14,X_12+15*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_49:=ROUND(SUM(IF(RANGE(CLOSE,X_12+16*X_14,X_12+17*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_50:=ROUND(SUM(IF(RANGE(CLOSE,X_12+18*X_14,X_12+19*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_51:=ROUND(SUM(IF(RANGE(CLOSE,X_12+21*X_14,X_12+22*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_52:=ROUND(SUM(IF(RANGE(CLOSE,X_12+23*X_14,X_12+24*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_53:=ROUND(SUM(IF(RANGE(CLOSE,X_12+25*X_14,X_12+26*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_54:=ROUND(SUM(IF(RANGE(CLOSE,X_12+27*X_14,X_12+28*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_55:=ROUND(SUM(IF(RANGE(CLOSE,X_12+29*X_14,X_12+30*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_56:=ROUND(SUM(IF(RANGE(CLOSE,X_12+31*X_14,X_12+32*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_57:=ROUND(SUM(IF(RANGE(CLOSE,X_12+33*X_14,X_12+34*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_58:=ROUND(SUM(IF(RANGE(CLOSE,X_12+35*X_14,X_12+36*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_59:=ROUND(SUM(IF(RANGE(CLOSE,X_12+37*X_14,X_12+38*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_60:=ROUND(SUM(IF(RANGE(CLOSE,X_12+38*X_14,X_12+39*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
X_61:=ROUND(SUM(IF(RANGE(CLOSE,X_12+39*X_14,X_12+40*X_14),VOL,0),X_1)/SUM(VOL,X_1)*X_15);
STICKLINE(CURRBARSCOUNT<=X_46,X_12+10*X_14,X_12+10.1*X_14,4,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_47,X_12+12*X_14,X_12+12.1*X_14,3.8,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_48,X_12+14*X_14,X_12+14.1*X_14,3.6,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_49,X_12+16*X_14,X_12+16.1*X_14,3.4,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_50,X_12+18*X_14,X_12+18.1*X_14,3.2,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_51,X_12+21*X_14,X_12+21.1*X_14,2.9,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_52,X_12+23*X_14,X_12+23.1*X_14,2.7,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_53,X_12+25*X_14,X_12+25.1*X_14,2.5,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_54,X_12+27*X_14,X_12+27.1*X_14,2.3,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_55,X_12+29*X_14,X_12+29.1*X_14,2,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_56,X_12+31*X_14,X_12+31.1*X_14,1.6,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_57,X_12+33*X_14,X_12+33.099998*X_14,0.8,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_58,X_12+35*X_14,X_12+35.099998*X_14,0.6,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_59,X_12+37*X_14,X_12+37.099998*X_14,0.4,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_60,X_12+38*X_14,X_12+38.099998*X_14,0.3,0),COLOR00AAAA;
STICKLINE(CURRBARSCOUNT<=X_61,X_12+39*X_14,X_12+39.099998*X_14,0.2,0),COLOR00AAAA;
X_62:=REF(CLOSE,1);
X_63:=CLOSE>=ZTPRICE(REF(CLOSE,1),0.03);
X_64:=CLOSE>=ZTPRICE(REF(CLOSE,1),0.05);
X_65:=CLOSE>=ZTPRICE(REF(CLOSE,1),0.07);
STICKLINE(X_63,CLOSE,OPEN,3,1),COLOR555555;
STICKLINE(X_63,CLOSE,OPEN,2,1),COLOR777777;
STICKLINE(X_63,CLOSE,OPEN,1,1),COLORCCCCCC;
STICKLINE(X_63,CLOSE,OPEN,0.3,1),COLORCCDDBB;
STICKLINE(X_64,CLOSE,OPEN,3,1),COLOR002288;
STICKLINE(X_64,CLOSE,OPEN,2,1),COLOR0033AA;
STICKLINE(X_64,CLOSE,OPEN,1,1),COLOR0055EE;
STICKLINE(X_64,CLOSE,OPEN,0.3,1),COLOR0088FF;
STICKLINE(X_65,CLOSE,OPEN,3,1),COLOR117777;
STICKLINE(X_65,CLOSE,OPEN,2,1),COLOR119999;
STICKLINE(X_65,CLOSE,OPEN,1,1),COLOR11BBBB;
STICKLINE(X_65,CLOSE,OPEN,0.3,1),COLOR44FFFF;
X_66:=50;
IF(CURRBARSCOUNT<=X_66,CONST(CLOSE),DRAWNULL),DOTLINE,COLOR00EEEE;
IF(CURRBARSCOUNT<=X_66,CONST(CLOSE)*0.9,DRAWNULL),DOTLINE,COLOR60A4F4;
IF(CURRBARSCOUNT<=X_66,CONST(CLOSE)*0.9*0.9,DRAWNULL),DOTLINE,COLOREEEEAE;
IF(CURRBARSCOUNT<=X_66,CONST(CLOSE)*0.9*0.9*0.95,DRAWNULL),DOTLINE,COLOR9AFF9A;
DRAWNUMBER(CURRBARSCOUNT=X_66+2,CONST(CLOSE),CONST(INTPART(WINNER(CLOSE)*100+0.5))),COLOR00EEEE;
DRAWNUMBER(CURRBARSCOUNT=X_66+2,CONST(CLOSE)*0.9,CONST(INTPART(WINNER(CLOSE*0.9)*100+0.5))),COLOR60A4F4;
DRAWNUMBER(CURRBARSCOUNT=X_66+2,CONST(CLOSE)*0.9*0.9,CONST(INTPART(WINNER(CLOSE*0.9*0.9)*100+0.5))),COLOREEEEAE;
DRAWNUMBER(CURRBARSCOUNT=X_66+2,CONST(CLOSE)*0.9*0.9*0.95,CONST(INTPART(WINNER(CLOSE*0.9*0.9*0.95)*100+0.5))),COLORWHITE;
DRAWTEXT(X_63,LOW*0.999,'金坑迎财神'),COLOR44FFFF;
YY:LLV(CLOSE,13),COLOR6803C7;
X_67:=(OPEN+LOW+HIGH+CLOSE)/4;
X_68:=EMA(X_67,5);
船长:HHV(X_68,60),COLORD8CFBB;
IF(船长>=REF(船长,1),船长,DRAWNULL),COLORRED;
IF(船长<=REF(船长,1),船长,DRAWNULL),COLORGREEN;

202108201145.jpg

202108201145.jpg

 

回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则