David902 发表于 2023-11-8 11:00:33

通达信公式 量学太极线通达信公式 主图 源码

<p data-first-child></p><p > 量学太极线</p><p >{通达信量学画线主图指标公式}</p><p > 均线数:=0;</p><p >画线虚实:=1;</p><p >显3121刻度:=0;</p><p >显买卖点:=1;</p><p >半分位:=(O+C)/2;</p><p >峰边距:=5;</p><p >回踩误差千分之:=2;</p><p >画将1黄2元3全4:=2;</p><p >精准计数周期:=240;</p><p >低1开2收3高4:=1;</p><p >基准点前N天:=0;</p><p >昨半分位:REF(半分位,1),NODRAW;</p><p > STICKLINE(ISLASTBAR,昨半分位,昨半分位,10,0);</p><p > DRAWTEXT(ISLASTBAR,昨半分位,' 昨半分位');</p><p > X_1:=1991015;</p><p > X_2:=TESTSKIP(DATE>X_1);</p><p > STICKLINE(REF(LOW,1)>HIGH,HIGH,REF(LOW,1),5,0),COLORGRAY;</p><p > STICKLINE(REF(HIGH,1)<LOW,LOW,REF(HIGH,1),5,0),COLORGRAY;</p><p > DRAWTEXT_FIX(ISLASTBAR,0,0,0,HYBLOCK);</p><p > DRAWTEXT_FIX(ISLASTBAR,0.05,0,0,DYBLOCK);</p><p > DRAWTEXT_FIX(ISLASTBAR,0.1,0,0,GNBLOCK);</p><p > DRAWTEXT_FIX(ISLASTBAR,0,0.045,0,FGBLOCK),COLORGREEN;</p><p > X_3:=240;</p><p > X_4:=CONST(HHV(REF(HIGH,1),X_3));</p><p > X_5:=CONST(LLV(REF(LOW,1),X_3));</p><p > X_6:=X_4-X_5;</p><p > X_7:=LOW-X_6*0.03;</p><p > X_8:=HIGH+X_6*0.03;</p><p > X_9:=CLOSE>500;</p><p > X_10:=MAX(CLOSE,OPEN);</p><p > X_11:=MIN(CLOSE,OPEN);</p><p > X_12:=基准点前N天;</p><p >X_13:=画线虚实;</p><p >X_14:=IF(X_9,HIGH,X_10);</p><p > X_15:=IF(X_9,LOW,X_11);</p><p > X_16:=IF(CLOSE>OPEN,IF(X_13=0,LOW,X_15),IF(X_13=0,HIGH,X_14));</p><p > X_17:=回踩误差千分之/1000;</p><p > X_18:=CURRBARSCOUNT;</p><p > X_19:=精准计数周期;</p><p >X_20:=X_18<=X_19;</p><p > X_21:=IF(低1开2收3高4=1,LOW,IF(低1开2收3高4=2,OPEN,IF(低1开2收3高4=3,CLOSE,HIGH)));</p><p > X_22:=IF(基准点前N天=0,X_21,REF(X_21,基准点前N天));</p><p >WEN98编_基准价:IF(X_20,CONST(X_22),DRAWNULL),DOTLINE,COLORLIGRAY;</p><p > X_23:=WEN98编_基准价;</p><p >X_24:=X_23*X_17;</p><p > X_25:=ABS(LOW-X_23)<=X_24;</p><p > X_26:=ABS(OPEN-X_23)<=X_24;</p><p > X_27:=ABS(CLOSE-X_23)<=X_24;</p><p > X_28:=ABS(HIGH-X_23)<=X_24;</p><p > X_29:=X_25 OR X_26 OR X_27 OR X_28 AND X_20 AND X_18!=基准点前N天+1;</p><p > X_30:=COUNT(X_29,X_19);</p><p >精准点个数:IF(X_30>0,X_30+1,0),NODRAW,COLORMAGENTA;</p><p > X_31:=峰边距;</p><p >X_32:=REF(HIGH,X_31)=HHV(HIGH,2*X_31+1);</p><p > X_33:=FILTER(X_32,X_31);</p><p > X_34:=BACKSET(X_33,X_31+1);</p><p > X_35:=FILTER(X_34,X_31);</p><p > X_36:=REF(HIGH,BARSLAST(X_35));</p><p > X_37:=REF(MAX(CLOSE,OPEN),X_31)=HHV(MAX(CLOSE,OPEN),2*X_31+1);</p><p > X_38:=FILTER(X_37,X_31);</p><p > X_39:=BACKSET(X_38,X_31+1);</p><p > X_40:=FILTER(X_39,X_31);</p><p > X_41:=REF(MAX(CLOSE,OPEN),BARSLAST(X_40));</p><p > X_42:=REF(LOW,X_31)=LLV(LOW,2*X_31+1);</p><p > X_43:=FILTER(X_42,X_31);</p><p > X_44:=BACKSET(X_43,X_31+1);</p><p > X_45:=FILTER(X_44,X_31);</p><p > X_46:=REF(LOW,BARSLAST(X_45));</p><p > X_47:=REF(MIN(CLOSE,OPEN),X_31)=LLV(MIN(CLOSE,OPEN),2*X_31+1);</p><p > X_48:=FILTER(X_47,X_31);</p><p > X_49:=BACKSET(X_48,X_31+1);</p><p > X_50:=FILTER(X_49,X_31);</p><p > X_51:=REF(MIN(CLOSE,OPEN),BARSLAST(X_50));</p><p > X_52:=IF(画线虚实=0,X_36,X_41);</p><p > X_53:=IF(画线虚实=0,X_46,X_51);</p><p > STICKLINE(X_52=REF(X_52,1) AND 峰边距>0,X_52,X_52,5,0),COLOR990099;</p><p > STICKLINE(X_53=REF(X_53,1) AND 峰边距>0,X_53,X_53,5,0),COLOR009900;</p><p > K中:(HIGH+LOW)/2,NODRAW,COLORYELLOW;</p><p > X_54:=MA(CLOSE,5);</p><p > MA5角度:ATAN((X_54/REF(X_54,1)-1)*100)*180/3.1416,NODRAW;</p><p > X_55:=均线数;</p><p >年线250:IF(X_55>=0 AND X_55<7,MA(CLOSE,250),DRAWNULL),COLORBLUE;</p><p >趋势120:IF(X_55>=0 AND X_55<7,MA(CLOSE,120),DRAWNULL),COLORFF00FF;</p><p >决策60:IF(X_55>=0 AND X_55<7,MA(CLOSE,60),DRAWNULL),COLORGREEN;</p><p >生命20:IF(X_55>=0 AND X_55<7,MA(CLOSE,20),DRAWNULL),COLORLIRED;</p><p > IF(X_55>=3 AND 生命20>=REF(生命20,1),生命20,DRAWNULL),COLORLIMAGENTA;</p><p >操盘10:IF(X_55>=0 AND X_55<7,MA(CLOSE,10),DRAWNULL),COLORYELLOW;</p><p >攻击5:IF(X_55>=0 AND X_55<7,MA(CLOSE,5),DRAWNULL),COLORWHITE;</p><p > IF(攻击5>REF(攻击5,1),攻击5,DRAWNULL),COLORMAGENTA;</p><p > IF(操盘10>REF(操盘10,1),操盘10,DRAWNULL),COLORYELLOW;</p><p > X_56:=FILTER(CROSS(KDJ.J,0) OR CROSS(KDJ.J,10),3);</p><p > DRAWICON(显买卖点=1 AND X_56 AND CLOSE>REF(CLOSE,1),X_7-X_6*0.03,1);</p><p > DRAWICON(显买卖点=1 AND CROSS(RSI.RSI1,20),X_7,1);</p><p > X_57:=REF(HHV(IF(X_13=1,X_10,HIGH),2),1);</p><p > X_58:=FILTER(CLOSE>X_57,1);</p><p > X_59:=REF(LLV(IF(X_13=1,X_11,LOW),2),1);</p><p > X_60:=FILTER(CLOSE<X_59,1);</p><p > X_61:=X_58 AND COUNT(X_58,BARSLAST(X_60))=1 AND 显买卖点=1;</p><p > X_62:=X_60 AND COUNT(X_60,BARSLAST(X_58))=1 AND 显买卖点=1;</p><p > STICKLINE(X_62,X_59,X_59,18,(-1)),COLORGREEN;</p><p > DRAWICON(X_62,X_8,39);{小图标_向下绿三角}</p><p > STICKLINE(X_61,X_57,X_57,18,(-1)),COLORMAGENTA;</p><p > DRAWICON(X_61,X_7,38);{小图标_向上红三角}</p><p > X_63:=1.01;</p><p > X_64:=IF(X_13=1,MIN(CLOSE,OPEN),LOW);</p><p > X_65:=VOL=REFX(HHV(VOL,8),3);</p><p > X_66:=X_65 AND BETWEEN(VOL/REF(VOL,1),1.01,5);</p><p > X_67:=VOL>REF(VOL,1);</p><p > X_68:=CLOSE/REF(CLOSE,1)>=1.03 OR CLOSE/OPEN>=1.03;</p><p > X_69:=CLOSE>OPEN OR CLOSE>REF(CLOSE,1);</p><p > X_70:=CLOSE>REF(MAX(CLOSE,OPEN),1);</p><p > X_71:=X_68;</p><p > X_72:=RANGE(VOL/REF(VOL,1),0.966,1.034) AND BARSCOUNT(VOL)>=2;</p><p > X_73:=X_70 AND REFX(X_72 AND COUNT(CLOSE>OPEN,2)=2,1);</p><p > X_74:=BETWEEN(VOL/REF(VOL,1),1.01,4.99) AND X_69;</p><p > X_75:=X_67 AND X_70;</p><p > X_76:=REFX(COUNT(VOL>=REF(VOL,1) AND X_69,2)=2,2);</p><p > X_77:=REFX(COUNT(BETWEEN(CLOSE/REF(CLOSE,1),1.001,1.04),2)=2,2);</p><p > X_78:=X_66 OR X_71 OR X_73 OR X_74 OR X_75 OR X_76 OR X_77;</p><p > X_79:=FILTER(X_69 AND X_78,0);</p><p > X_80:=LLV(CLOSE,3)>=REF(MIN(CLOSE,OPEN),3);</p><p > X_81:=1*(X_79 AND REFX(X_80,3));</p><p > X_82:=EMA(VOL,3)<=REF(VOL,3)*1.03;</p><p > X_83:=(EMA(VOL,3)-REF(VOL,3))/REF(VOL,3)<=(EMA(CLOSE,3)-REF(CLOSE,3))/REF(CLOSE,3);</p><p >DRAWTEXT_FIX(1,0.980,20,1,'★云指标公式网'),COLOR666666; </p><p > X_84:=X_82 OR X_83;</p><p > X_85:=REFX(MIN(EMA(CLOSE,3),CLOSE),3)>=CLOSE;</p><p > X_86:=1*(X_81 AND REFX(X_84,3) AND X_85);</p><p > X_87:=COUNT(VOL<=REF(VOL,1),3)=3;</p><p > X_88:=COUNT(CLOSE>=REF(CLOSE,1),3)=3;</p><p > X_89:=COUNT(CLOSE>OPEN,4)=4;</p><p > X_90:=X_87 AND X_88 AND X_89;</p><p > X_91:=REFX(X_90,3);</p><p > X_92:=MIN(CLOSE,OPEN)>REF(MAX(CLOSE,OPEN),1);</p><p > X_93:=1*(X_69 AND REFX(X_86,1) AND MAX(CLOSE,OPEN)<REFX(OPEN,1));</p><p > X_94:=画将1黄2元3全4;</p><p > X_95:=BARSLAST(X_81 AND REF(X_81=0,1));</p><p > X_96:=REF(X_64,X_95);</p><p > X_97:=X_94=1 OR X_94=4;</p><p > STICKLINE(X_97,X_96,X_96,3,0),COLORWHITE;</p><p > X_98:=BARSLAST(X_86 AND REF(X_86=0,1));</p><p > X_99:=REF(X_64,X_98);</p><p > X_100:=X_94=2 OR X_94=4 OR X_94=5;</p><p > STICKLINE(X_100,X_99,X_99,3,0),COLORYELLOW;</p><p > X_101:=REF(LLV(X_64,3),X_98-3);</p><p > STICKLINE(X_94=5,X_101,X_101,21,(-1)),COLORYELLOW;</p><p > X_102:=BARSLAST(X_93 AND REF(X_93=0,1));</p><p > X_103:=REF(MAX(CLOSE,OPEN),X_102);</p><p > X_104:=X_94=3 OR X_94=4;</p><p > STICKLINE(X_104,X_103,X_103,3,0),COLORLIRED;</p><p > X_105:=ABS(X_36-X_23)<=X_24;</p><p > X_106:=ABS(X_41-X_23)<=X_24;</p><p > X_107:=FILTER(X_105 OR X_106,480) AND X_20;</p><p > X_108:=ABS(X_46-X_23)<=X_24;</p><p > X_109:=ABS(X_51-X_23)<=X_24;</p><p > X_110:=FILTER(X_108 OR X_109,480) AND X_20;</p><p > X_111:=COUNT(X_110,X_19) AND COUNT(X_107,X_19) AND X_18=15;</p><p > DRAWLINE(X_107 AND 峰边距>0,X_23,1,X_23,0),COLORLIRED;</p><p > DRAWLINE(X_110 AND 峰边距>0,X_23,1,X_23,0),COLORGREEN;</p><p > DRAWLINE(X_111 AND 峰边距>0,X_23,1,X_23,1),COLORMAGENTA;</p><p > X_112:=ABS(X_99-X_23)<=X_24;</p><p > X_113:=ABS(X_101-X_23)<=X_24;</p><p > X_114:=ABS(X_103-X_23)<=X_24;</p><p > X_115:=FILTER(X_112 OR X_113 OR X_114,480) AND X_20;</p><p > DRAWLINE(X_115,X_23,1,X_23,0),COLORBROWN;</p><p > X_116:=REF(CLOSE,1);</p><p > X_117:=IF(CLOSE>=1,10000,100000);</p><p > X_118:=1.1*X_116-49/X_117;</p><p > X_119:=1.05*X_116-49/X_117;</p><p > X_120:=0.9*X_116+51/X_117;</p><p > X_121:=0.95*X_116+51/X_117;</p><p > X_122:=NAMELIKE(1) OR NAMELIKE(2);</p><p > X_123:=IF(X_122,CLOSE>=X_119,CLOSE>=X_118);</p><p > X_124:=IF(X_122,CLOSE<=X_121,CLOSE<=X_120);</p><p > X_125:=IF(X_122,HIGH>=X_119,HIGH>=X_118);</p><p > X_126:=IF(X_122,LOW<=X_121,LOW<=X_120);</p><p > X_127:=CLOSE>OPEN AND (CLOSE>=X_119 OR CLOSE>1.05*OPEN-51/X_117) OR (CLOSE>1000 AND CLOSE>X_116*1.024);</p><p > X_128:=CLOSE<OPEN AND (CLOSE<=X_121 OR CLOSE<0.95*OPEN+49/X_117) OR (CLOSE>1000 AND CLOSE<X_116*0.976);</p><p > X_129:=BARSLAST(FILTER(X_127,3));</p><p > X_130:=REF(X_16,X_129);</p><p >阳底:IF(显3121刻度=0 AND REF(X_127,X_129) AND X_130=REF(X_130,1),X_130,DRAWNULL),DOTLINE,COLORYELLOW;</p><p > X_131:=BARSLAST(FILTER(X_128,3));</p><p > X_132:=REF(X_16,X_131);</p><p >阴顶:IF(显3121刻度=0 AND REF(X_128,X_131) AND X_132=REF(X_132,1),X_132,DRAWNULL),DOTLINE,COLORGREEN;</p><p > DRAWKLINE(HIGH,OPEN,LOW,CLOSE);</p><p > STICKLINE(X_125,HIGH,MAX(CLOSE,OPEN),0,0),COLORMAGENTA;</p><p > STICKLINE(X_126,LOW,MIN(CLOSE,OPEN),0,0),COLORLICYAN;</p><p > STICKLINE(X_127,OPEN,CLOSE,1,0),COLOR0000BB;</p><p > STICKLINE(X_128,OPEN,CLOSE,1,0),COLORLIGREEN;</p><p > STICKLINE(X_123,OPEN,CLOSE,1,0),COLORMAGENTA;</p><p > STICKLINE(X_124,OPEN,CLOSE,1,0),COLORLICYAN;</p><p > X_133:=CLOSE>OPEN AND CLOSE<X_116;</p><p > STICKLINE(X_133,OPEN,CLOSE,0,0),COLORGREEN;</p><p > X_134:=CLOSE<OPEN AND CLOSE>X_116;</p><p > STICKLINE(X_134,OPEN,CLOSE,0,0),COLORRED;</p><p > X_135:=AMOUNT/VOL/100;</p><p > X_136:=CLOSE<OPEN AND X_135>REF(CLOSE,1) AND CLOSE<=X_116 AND X_135<=HIGH;</p><p > STICKLINE(X_136,X_135,X_135,1,0),COLORRED;</p><p > X_137:=PERIOD=5 AND NAMELIKE(10) AND (ABS(CLOSE-REF(CLOSE,1))/REF(CLOSE,1)>=0.025 OR ABS(CLOSE-OPEN)>=60);</p><p > X_138:=X_14-(X_14-X_15)/3;</p><p > X_139:=X_15+(X_14-X_15)/3;</p><p > X_140:=X_15+(X_14-X_15)/2;</p><p > X_141:=1+IF(X_9,2,4.92)/100;</p><p > X_142:=X_14/X_15>=X_141 OR CLOSE/REF(CLOSE,1)>=X_141;</p><p > X_143:=显3121刻度=1 AND X_142;</p><p > C31:IF(X_143,X_138,DRAWNULL),POINTDOT,COLORWHITE;</p><p > C21:IF(X_143,X_140,DRAWNULL),POINTDOT,COLORWHITE;</p><p > C32:IF(X_143,X_139,DRAWNULL),POINTDOT,COLORWHITE;</p><p > X_144:=1;</p><p > X_145:=显3121刻度=2 AND X_142;</p><p > STICKLINE(X_145,X_138,X_138,X_144,0),COLORYELLOW;</p><p > STICKLINE(X_145,X_140,X_140,X_144,0),COLORYELLOW;</p><p > STICKLINE(X_145,X_139,X_139,X_144,0),COLORYELLOW;</p><p > DRAWICON(X_18=基准点前N天+1,X_7,1);</p><p > STICKLINE(X_29,X_23,X_23,3,1),COLORYELLOW;</p><p > STICKLINE(X_18=基准点前N天+1,X_23,X_23,3,1),COLORYELLOW;</p><p > X_146:=IF(X_13=0,BARSLAST(X_35)>0,BARSLAST(X_40)>0) AND (ABS(LOW-X_52)<=X_52*X_17 OR ABS(X_11-X_52)<=X_52*X_17);</p><p > X_147:=IF(X_13=0,BARSLAST(X_45)>0,BARSLAST(X_50)>0) AND (ABS(LOW-X_53)<=X_53*X_17 OR ABS(X_11-X_53)<=X_53*X_17);</p><p > STICKLINE(X_146,X_52,X_52,1,1),COLORYELLOW;</p><p > STICKLINE(X_147,X_53,X_53,1,1),COLORYELLOW;</p><p >DRAWNUMBER(ISLASTBAR,C,C),COLORYELLOW; </p>

123458384 发表于 2024-2-8 13:57:27

路过,帮顶一下!

智商堪忧岩 发表于 2024-2-8 19:46:17

真是 收益 匪浅
页: [1]
查看完整版本: 通达信公式 量学太极线通达信公式 主图 源码