通达信量学主图指标源码

[复制链接]
查看166 | 回复0 | 2021-8-26 22:35:38 | 显示全部楼层 |阅读模式

以下是通达信量学主图指标源码(无源码的请下载附件导入)

STICKLINE(CLOSE>1.095*REF(CLOSE,1),CLOSE,OPEN,3,0),COLORYELLOW;
 STICKLINE(CLOSE<0.905*REF(CLOSE,1),CLOSE,OPEN,3,0),COLORWHITE;
 X_1:=1.3;
 X_2:=1;
 X_3:=0;
 X_4:=MA(CLOSE,5);
 X_5:=MA(CLOSE,10);
 X_6:=MA(CLOSE,20);
 X_7:=X_4>REF(X_4,1) AND X_5<REF(X_5,1) AND X_6<REF(X_6,1);
 X_8:=REF(VOL,1);
 X_9:=REF(VOL,2);
 X_10:=REF(VOL,3);
 X_11:=REF(CLOSE,1);
 X_12:=REF(CLOSE,2);
 X_13:=REF(CLOSE,3);
 X_14:=REF(CLOSE,4);
 X_15:=REF(OPEN,1);
 X_16:=REF(OPEN,2);
 X_17:=REF(OPEN,3);
 X_18:=REF(OPEN,4);
 X_19:=CLOSE>=X_13 AND X_11>=X_13 AND X_12>=X_13;
 X_20:=LOW>X_17 AND REF(LOW,1)>X_17 AND REF(LOW,2)>X_17;
 X_21:=AMOUNT/VOL/100;
 X_22:=REF(X_21,1);
 X_23:=REF(X_21,2);
 X_24:=CLOSE>=OPEN OR (CLOSE<OPEN AND X_21>X_11);
 X_25:=COUNT(X_24,3)>=2;
 X_26:=X_13>X_17;
 X_27:=X_21>=X_22 OR CLOSE>X_11 AND (X_22>=X_23 OR X_11>=X_12);
 X_28:=(CLOSE+X_11+X_12)/3>X_13;
 X_29:=VOL>X_8 AND X_8>X_9;
 X_30:=VOL<=X_8 AND X_8<=X_9;
 X_31:=(VOL+X_8+X_9)/3<=X_10 AND NOT(X_29);
 X_32:=CLOSE/VOL;
 X_33:=X_32>=REF(X_32,1) AND REF(X_32,1)>=REF(X_32,2);
 X_34:=(CLOSE+X_11+X_12)/3/X_13;
 X_35:=(VOL+X_8+X_9)/3/X_10;
 X_36:=X_1*X_34/X_35>1;
 X_37:=X_17>X_14 AND X_14>X_18;
 X_38:=X_26 AND X_27 AND X_30 AND X_19 AND X_20 AND X_37;
 X_39:=BACKSET(X_38,5);
 X_40:=FILTER(X_39,4);
 X_41:=X_26 AND X_27 AND X_30 AND X_19 AND X_20;
 X_42:=BACKSET(X_41,4);
 X_43:=FILTER(X_42,3);
 X_44:=X_41 AND REF(X_41,1);
 X_45:=BACKSET(X_44,4);
 X_46:=FILTER(X_45,3);
 X_47:=X_41 AND REF(X_41,2);
 X_48:=BACKSET(X_47,4);
 X_49:=FILTER(X_48,3);
 X_50:=X_41 AND REF(X_41,3);
 X_51:=BACKSET(X_50,4);
 X_52:=FILTER(X_51,3);
 X_53:=X_26 AND X_27 AND X_31 AND NOT(X_29) AND X_19 AND X_20 AND X_37 AND NOT(X_41) AND NOT(X_38);
 X_54:=BACKSET(X_53,5);
 X_55:=FILTER(X_54,4);
 X_56:=X_26 AND X_27 AND X_31 AND NOT(X_29) AND X_19 AND X_20 AND NOT(X_41) AND NOT(X_38);
 X_57:=BACKSET(X_56,4);
 X_58:=FILTER(X_57,3);
 X_59:=X_56 AND REF(X_56,1);
 X_60:=BACKSET(X_59,4);
 X_61:=FILTER(X_60,3);
 X_62:=X_56 AND REF(X_56,2);
 X_63:=BACKSET(X_62,4);
 X_64:=FILTER(X_63,3);
 X_65:=X_56 AND REF(X_56,3);
 X_66:=BACKSET(X_65,4);
 X_67:=FILTER(X_66,3);
 X_68:=X_26 AND X_28 AND X_30 AND X_19 AND X_20 AND X_37 AND NOT(X_41) AND NOT(X_56) AND NOT(X_38) AND NOT(X_53);
 X_69:=BACKSET(X_68,5);
 X_70:=FILTER(X_69,4);
 X_71:=X_26 AND X_28 AND X_30 AND X_19 AND X_20 AND NOT(X_41) AND NOT(X_56) AND NOT(X_38) AND NOT(X_53);
 X_72:=BACKSET(X_71,4);
 X_73:=FILTER(X_72,3);
 X_74:=X_71 AND REF(X_71,1);
 X_75:=BACKSET(X_74,4);
 X_76:=FILTER(X_75,3);
 X_77:=X_71 AND REF(X_71,2);
 X_78:=BACKSET(X_77,4);
 X_79:=FILTER(X_78,3);
 X_80:=X_71 AND REF(X_71,3);
 X_81:=BACKSET(X_80,4);
 X_82:=FILTER(X_81,3);
 X_83:=X_26 AND X_28 AND X_31 AND X_19 AND X_20 AND X_37 AND NOT(X_41) AND NOT(X_38) AND NOT(X_56) AND NOT(X_53) AND NOT(X_71) AND NOT(X_68);
 X_84:=BACKSET(X_83,5);
 X_85:=FILTER(X_84,4);
 X_86:=X_26 AND X_28 AND X_31 AND X_19 AND X_20 AND NOT(X_41) AND NOT(X_56) AND NOT(X_71) AND NOT(X_38) AND NOT(X_53) AND NOT(X_68);
 X_87:=BACKSET(X_86,4);
 X_88:=FILTER(X_87,3);
 X_89:=X_86 AND REF(X_86,1);
 X_90:=BACKSET(X_89,4);
 X_91:=FILTER(X_90,3);
 X_92:=X_86 AND REF(X_86,2);
 X_93:=BACKSET(X_92,4);
 X_94:=FILTER(X_93,3);
 X_95:=X_86 AND REF(X_86,3);
 X_96:=BACKSET(X_95,4);
 X_97:=FILTER(X_96,3);
 X_98:=X_26 AND X_28 AND X_36 AND X_19 AND X_20 AND X_37 AND NOT(X_41) AND NOT(X_56) AND NOT(X_71) AND NOT(X_86) AND NOT(X_38) AND NOT(X_53) AND NOT(X_68) AND NOT(X_83);
 X_99:=BACKSET(X_98,5);
 X_100:=FILTER(X_99,4);
 X_101:=X_26 AND X_28 AND X_36 AND X_19 AND X_20 AND NOT(X_41) AND NOT(X_56) AND NOT(X_71) AND NOT(X_86) AND NOT(X_38) AND NOT(X_53) AND NOT(X_68) AND NOT(X_83);
 X_102:=BACKSET(X_101,4);
 X_103:=FILTER(X_102,3);
 X_104:=X_101 AND REF(X_101,1);
 X_105:=BACKSET(X_104,4);
 X_106:=FILTER(X_105,3);
 X_107:=X_101 AND REF(X_101,2);
 X_108:=BACKSET(X_107,4);
 X_109:=FILTER(X_108,3);
 X_110:=X_101 AND REF(X_101,3);
 X_111:=BACKSET(X_110,4);
 X_112:=FILTER(X_111,3);
 X_113:=X_26 AND X_28 AND X_33 AND X_19 AND X_20 AND X_37 AND NOT(X_41) AND NOT(X_56) AND NOT(X_71) AND NOT(X_86) AND NOT(X_101) AND NOT(X_38) AND NOT(X_53) AND NOT(X_68) AND NOT(X_83) AND NOT(X_98);
 X_114:=BACKSET(X_113,5);
 X_115:=FILTER(X_114,4);
 X_116:=X_26 AND X_28 AND X_33 AND X_19 AND X_20 AND NOT(X_41) AND NOT(X_56) AND NOT(X_71) AND NOT(X_86) AND NOT(X_101) AND NOT(X_38) AND NOT(X_53) AND NOT(X_68) AND NOT(X_83) AND NOT(X_98);
 X_117:=BACKSET(X_116,4);
 X_118:=FILTER(X_117,3);
 X_119:=X_116 AND REF(X_116,1);
 X_120:=BACKSET(X_119,4);
 X_121:=FILTER(X_120,3);
 X_122:=X_116 AND REF(X_116,2);
 X_123:=BACKSET(X_122,4);
 X_124:=FILTER(X_123,3);
 X_125:=X_116 AND REF(X_116,3);
 X_126:=BACKSET(X_125,4);
 X_127:=FILTER(X_126,3);
 X_128:=X_43 AND NOT(REF(X_43,4)) OR (X_46 AND NOT(REF(X_46,4))) OR (X_49 AND NOT(REF(X_49,4))) OR (X_52 AND NOT(REF(X_52,4)));
 X_129:=X_58 AND NOT(REF(X_58,4)) OR (X_61 AND NOT(REF(X_61,4))) OR (X_64 AND NOT(REF(X_64,4))) OR (X_67 AND NOT(REF(X_67,4)));
 X_130:=X_73 AND NOT(REF(X_73,4)) OR (X_76 AND NOT(REF(X_76,4))) OR (X_79 AND NOT(REF(X_79,4))) OR (X_82 AND NOT(REF(X_82,4)));
 X_131:=X_88 AND NOT(REF(X_88,4)) OR (X_91 AND NOT(REF(X_91,4))) OR (X_94 AND NOT(REF(X_94,4))) OR (X_97 AND NOT(REF(X_97,4)));
 X_132:=X_103 AND NOT(REF(X_103,4)) OR (X_106 AND NOT(REF(X_106,4))) OR (X_109 AND NOT(REF(X_109,4))) OR (X_112 AND NOT(REF(X_112,4)));
 X_133:=X_118 AND NOT(REF(X_118,4)) OR (X_121 AND NOT(REF(X_121,4))) OR (X_124 AND NOT(REF(X_124,4))) OR (X_127 AND NOT(REF(X_127,4)));
 X_134:=X_128 OR X_129 OR X_130 OR X_131 OR X_132 OR X_133;
 STICKLINE(X_134,OPEN,CLOSE,1.2,0),COLORYELLOW;
 X_135:=FILTER(X_134,3);
 STICKLINE(X_135,OPEN,CLOSE,1.75,0),COLORYELLOW;
 STICKLINE(X_135,OPEN,CLOSE,0.75,0),COLORRED;
 STICKLINE(X_134 AND VOL/REF(VOL,1)>=1.95,OPEN,CLOSE,0.01,0),COLORBROWN;
 X_136:=SUMBARS(X_135,1);
 STICKLINE(X_136 AND X_2=1,REF(CLOSE,X_136-1),REF(CLOSE,X_136-1),10,0),COLORAA00FF;
 STICKLINE(X_136 AND X_2=1,REF(LOW,X_136-1),REF(LOW,X_136-1),10,0),COLORYELLOW;
 X_137:=X_40 AND NOT(REF(X_40,5));
 X_138:=X_55 AND NOT(REF(X_55,5));
 X_139:=X_70 AND NOT(REF(X_70,5));
 X_140:=X_85 AND NOT(REF(X_85,5));
 X_141:=X_100 AND NOT(REF(X_100,5));
 X_142:=X_115 AND NOT(REF(X_115,5));
 X_143:=X_137 OR X_138 OR X_139 OR X_140 OR X_141 OR X_142;
 STICKLINE(X_143,OPEN,CLOSE,0.5,0),COLORMAGENTA;
 X_144:=FILTER(X_143,3);
 STICKLINE(X_144 AND NOT(REF(X_143,5)),OPEN,CLOSE,2,0),COLORYELLOW;
 STICKLINE(X_144 AND NOT(REF(X_143,5)),OPEN,CLOSE,1,0),COLORMAGENTA;
 X_145:=SUMBARS(X_143,1);
 STICKLINE(CLOSE>OPEN AND REF(CLOSE,1)<REF(OPEN,1) AND HIGH<REF(OPEN,1) AND CLOSE<(REF(OPEN,1)-REF(CLOSE,1))/2+REF(CLOSE,1),CLOSE,OPEN,0.57,0),COLORGREEN;
 STICKLINE(OPEN>CLOSE AND CLOSE>REF(CLOSE,1) AND REF(CLOSE,1)>=REF(OPEN,1),CLOSE,OPEN,0.37,0),COLORRED;
 DRAWICON(VOL<=MA(VOL,60)*1/3 AND VOL<REF(LLV(VOL,100),1) OR (VOL/REF(VOL,1)<=0.51 AND VOL<REF(LLV(VOL,100),1)) AND HIGH>LOW,LOW*0.99,1);
 X_146:=STRCAT(HYBLOCK,1);
 X_147:=STRCAT(X_146,FGBLOCK);
 X_148:=STRCAT(X_147,DYBLOCK);
 X_149:=STRCAT(X_148,ZDBLOCK);
 X_150:=STRCAT(X_149,1);
 DRAWTEXT_FIX(ISLASTBAR,0,0,0,STRCAT(X_150,GNBLOCK)),COLORYELLOW;
 X_151:=3;
 X_152:=0;
 X_153:=ABS(LOW-REF(LOW,1))<=X_152;
 X_154:=ABS(LOW-REF(LOW,2))<=X_152;
 X_155:=ABS(LOW-REF(LOW,3))<=X_152;
 X_156:=ABS(LOW-REF(LOW,4))<=X_152;
 X_157:=ABS(LOW-REF(LOW,5))<=X_152;
 X_158:=X_153 OR X_154 OR X_155 OR X_156 OR X_157;
 X_159:=FILTER(X_158,X_151);
 X_160:=BARSLAST(X_159);
 X_161:=REF(LOW,X_160);
 X_162:=ABS(LOW-X_161)<=X_152;
 STICKLINE(X_159,LOW,LOW,31,(-1)),COLORMAGENTA;
 X_163:=ABS(HIGH-REF(HIGH,1))<=X_152;
 X_164:=ABS(HIGH-REF(HIGH,2))<=X_152;
 X_165:=ABS(HIGH-REF(HIGH,3))<=X_152;
 X_166:=ABS(HIGH-REF(HIGH,4))<=X_152;
 X_167:=ABS(HIGH-REF(HIGH,5))<=X_152;
 X_168:=X_163 OR X_164 OR X_165 OR X_166 OR X_167;
 X_169:=FILTER(X_168,X_151);
 X_170:=BARSLAST(X_169);
 X_171:=REF(HIGH,X_170);
 X_172:=ABS(HIGH-X_171)<=X_152;
 STICKLINE(X_169,HIGH,HIGH,31,(-1)),COLORGREEN;
 STICKLINE(CLOSE/REF(CLOSE,1)>=1.04 OR CLOSE/REF(CLOSE,1)<=0.96,(CLOSE+OPEN)/2,(CLOSE+OPEN)/2,2,1),COLORLIBLUE;
 STICKLINE(CLOSE/REF(CLOSE,1)>=1.04 OR CLOSE/REF(CLOSE,1)<=0.96,(MAX(OPEN,CLOSE)-MIN(OPEN,CLOSE))*2/3+MIN(OPEN,CLOSE),(MAX(OPEN,CLOSE)-MIN(OPEN,CLOSE))*2/3+MIN(OPEN,CLOSE),2,1),COLORLIBLUE;
 STICKLINE(CLOSE/REF(CLOSE,1)>=1.04 OR CLOSE/REF(CLOSE,1)<=0.96,(MAX(OPEN,CLOSE)-MIN(OPEN,CLOSE))/3+MIN(OPEN,CLOSE),(MAX(OPEN,CLOSE)-MIN(OPEN,CLOSE))/3+MIN(OPEN,CLOSE),2,1),COLORLIBLUE;
中分线:(OPEN+CLOSE)/2,NODRAW,COLORRED;
上31:(MAX(OPEN,CLOSE)-MIN(OPEN,CLOSE))*2/3+MIN(OPEN,CLOSE),NODRAW,COLORMAGENTA;
下31:(MAX(OPEN,CLOSE)-MIN(OPEN,CLOSE))/3+MIN(OPEN,CLOSE),NODRAW,COLORYELLOW;
 X_173:=REF(LOW,1);
 X_174:=REF(HIGH,1);
 X_175:=LOW>X_174;
 X_176:=HIGH<X_173;
 STICKLINE(LOW>REF(HIGH,1),LOW,REF(HIGH,1),2.78,(-1)),COLORRED;
 STICKLINE(REF(LOW,1)>HIGH,REF(LOW,1),HIGH,2.78,(-1)),COLORGREEN;
 X_177:=0;
 X_178:=0.085;
 X_179:=IF(GNBLOCK=DRAWNULL,11,STRCAT(12,GNBLOCK));
 X_180:=IF(FGBLOCK=DRAWNULL,11,STRCAT(13,FGBLOCK));
 X_181:=IF(ZHBLOCK=DRAWNULL,11,STRCAT(14,ZHBLOCK));
 X_182:=STRCAT(X_179,STRCAT(X_180,X_181));
 X_183:=IF(GNBLOCK=DRAWNULL,11,STRCAT(15,GNBLOCK));
 X_184:=IF(FGBLOCK=DRAWNULL,11,STRCAT(15,FGBLOCK));
 X_185:=IF(ZHBLOCK=DRAWNULL,11,STRCAT(15,ZHBLOCK));
 X_186:=STRCAT(X_183,STRCAT(X_184,X_185));
 DRAWTEXT_FIX(IF(CODELIKE(16) OR CODELIKE(17) OR CODELIKE(18) OR NAMELIKE(19),DRAWNULL,1),X_177,X_178,0,X_186),COLORRED;
 DRAWTEXT_FIX(IF(CODELIKE(16) OR CODELIKE(17) OR CODELIKE(18) OR NAMELIKE(19),DRAWNULL,1),X_177,X_178,0,X_182),COLORWHITE;
 DRAWTEXT_FIX(1,0.02,0.19,0,20),COLORRED;

841255725.png

841255725.png

回复

使用道具 举报

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

本版积分规则