通达信操盘短线短线副图,五指山万泉河 源码分享
X_1:=IF(TIME>93000 AND TIME<94500,1,0);
X_2:=IF(TIME>93100 AND TIME<145500,1,0);
X_3:=IF(TIME>100000 AND TIME<145500,1,0);
X_4:=IF(TIME>140000 AND TIME<145500,1,0);
X_5:=IF(TIME>142500 AND TIME<145500,1,0);
X_6:=DYNAINFO(14)*100;
X_7:=DYNAINFO(8);
X_8:=FILTER(X_7=0,350);
DRAWTEXT(X_8,45,22),COLORMAGENTA;
X_9:=IF(TROUGHBARS(3,16,1)=0 AND HIGH>LOW+0.04,3,0);
X_10:=ZIG(3,6)>REF(ZIG(3,6),1) AND REF(ZIG(3,6),1)<=REF(ZIG(3,6),2) AND REF(ZIG(3,6),2)<=REF(ZIG(3,6),3);
X_11:=ZIG(3,22)>REF(ZIG(3,22),1) AND REF(ZIG(3,22),1)<=REF(ZIG(3,22),2) AND REF(ZIG(3,22),2)<=REF(ZIG(3,22),3);
X_12:=ZIG(3,51)>REF(ZIG(3,51),1) AND REF(ZIG(3,51),1)<=REF(ZIG(3,51),2) AND REF(ZIG(3,51),2)<=REF(ZIG(3,51),3);
X_13:=ZIG(3,72)>REF(ZIG(3,72),1) AND REF(ZIG(3,72),1)<=REF(ZIG(3,72),2) AND REF(ZIG(3,72),2)<=REF(ZIG(3,72),3);
X_14:=X_9;
X_15:=X_10+X_11+X_12+X_13;
X_16:=ZIG(3,6)<REF(ZIG(3,6),1) AND REF(ZIG(3,6),1)>=REF(ZIG(3,6),2) AND REF(ZIG(3,6),2)>=REF(ZIG(3,6),3);
X_17:=ZIG(3,22)<REF(ZIG(3,22),1) AND REF(ZIG(3,22),1)>=REF(ZIG(3,22),2) AND REF(ZIG(3,22),2)>=REF(ZIG(3,22),3);
X_18:=ZIG(3,51)<REF(ZIG(3,51),1) AND REF(ZIG(3,51),1)>=REF(ZIG(3,51),2) AND REF(ZIG(3,51),2)>=REF(ZIG(3,51),3);
X_19:=ZIG(3,72)<REF(ZIG(3,72),1) AND REF(ZIG(3,72),1)>=REF(ZIG(3,72),2) AND REF(ZIG(3,72),2)>=REF(ZIG(3,72),3);
X_20:=X_16+X_17+X_18+X_19;
X_21:=IF(X_20>0,(-500),0);
X_22:=IF(CLOSE>1000,X_21*100,X_21);
CT:SUM(X_22,0) AND X_2=1;
五指山:EMA((CLOSE-LLV(CLOSE,55))/(HHV(CLOSE,55)-LLV(LOW,55))*100,5),COLORMAGENTA;
X_23:=7*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*30,4,1)-3*SMA(SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*30,4,1),3,1)-SMA(SMA(SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*30,4,1),3,1),2,1);
万泉河:EMA(MA(X_23,5),3),COLORCYAN;
X_24:=五指山;
X_25:=万泉河;
X_26:=IF(X_2=1 AND X_24>80 AND CT=1,1,0);
X_27:=FILTER(X_26=1,350);
X_28:=23;
DRAWTEXT(X_27,45,X_28),COLORGREEN;
X_29:=(CLOSE-LLV(LOW,36))/(HHV(HIGH,36)-LLV(LOW,36))*100;
X_30:=SMA(X_29,3,1);
X_31:=SMA(X_30,3,1);
X_32:=SMA(X_31,3,1);
X_33:=EMA(WINNER(CLOSE),10);
X_34:=EMA(WINNER(CLOSE),34);
X_35:=MA(CLOSE,32);
X_36:=MA(CLOSE,12);
X_37:=CROSS(X_34,X_33);
X_38:=MA(CLOSE,1);
X_39:=MA(X_35,2);
X_40:=(CLOSE-LLV(LOW,60))/(HHV(HIGH,60)-LLV(LOW,60))*80;
X_41:=SMA(X_40,7,1);
X_42:=(LOW+HIGH+CLOSE)/3;
X_43:=(X_42-MA(X_42,14))/(0.015*AVEDEV(X_42,14));
X_44:=100*(HHV(HIGH,79)-CLOSE)/(HHV(HIGH,79)-LLV(LOW,79));
X_45:=(2*CLOSE+HIGH+LOW+OPEN)/5;
X_46:=LLV(LOW,34);
X_47:=HHV(HIGH,34);
X_48:=EMA((X_45-X_46)/(X_47-X_46)*100,13);
X_49:=IF(X_44=0 OR X_48>=90 OR X_43>(-250),100,X_44);
舟:IF(X_14>0 OR X_15>0,35,DRAWNULL)*2,STICK,COLORMAGENTA,LINETHICK3;
岸:(X_2=1 AND CT=0 AND X_48=100 OR X_2=1 AND CT=0 AND X_48>0 AND X_44>98 AND X_48<=13)*60,STICK,COLORMAGENTA;
花:EMA(IF(X_25<15 AND X_4=1 AND LOW<=LLV(LOW,30),SMA(ABS(LOW-REF(LOW,1)),30,1)/SMA(MAX(LOW-REF(LOW,1),0),30,1),0),3)*25,STICK,COLORYELLOW,LINETHICK3;
X_50:=CROSS(X_23,X_25);
X_51:=X_24<35 AND X_24>MA(REF(X_24,3),3) AND CT=0 AND X_3=1 AND X_6<8;
技:IF(X_50=1 AND X_51=1,75,0),STICK,COLORRED,LINETHICK3;
X_52:=FILTER(技,16);
DRAWTEXT(X_52,25,24),COLORYELLOW;
X_53:=ZIG(3,5)>REF(ZIG(3,5),1) AND REF(ZIG(3,5),1)<=REF(ZIG(3,5),2) AND REF(ZIG(3,5),2)<=REF(ZIG(3,5),3);
看涨:X_53=1;
CH:SUM(看涨,0) AND X_2=1;
X_54:=FILTER(看涨,16);
DRAWTEXT(X_54,30,25),COLORYELLOW,LINETHICK2;
X_55:=REF(CLOSE,1);
X_56:=SMA(MAX(CLOSE-X_55,0),7,1)/SMA(ABS(CLOSE-X_55),7,1)*100;
X_57:=SMA(MAX(CLOSE-X_55,0),13,1)/SMA(ABS(CLOSE-X_55),13,1)*100;
X_58:=SMA(MAX(X_55-CLOSE,0),7,1)/SMA(ABS(CLOSE-X_55),7,1)*100;
X_59:=SMA(MAX(X_55-CLOSE,0),13,1)/SMA(ABS(CLOSE-X_55),13,1)*100;
X_60:=BARSCOUNT(CLOSE);
波:(X_4=1 AND X_56<25 AND X_57<30 AND X_60>35)*3,COLORSTICK,LINETHICK2;
X_61:=100-3*SMA((CLOSE-LLV(LOW,65))/(HHV(HIGH,80)-LLV(LOW,65))*100,20,1)+2*SMA(SMA((CLOSE-LLV(LOW,65))/(HHV(HIGH,80)-LLV(LOW,65))*100,20,1),15,1);
X_62:=100-3*SMA((OPEN-LLV(LOW,65))/(HHV(HIGH,80)-LLV(LOW,65))*100,20,1)+2*SMA(SMA((OPEN-LLV(LOW,65))/(HHV(HIGH,80)-LLV(LOW,65))*100,20,1),15,1);
X_63:=X_61<REF(X_62,1) AND VOL>REF(VOL,1) AND CLOSE>REF(CLOSE,1);
DRAWTEXT(CT=0 AND X_63 AND COUNT(X_63,50)=1,75,26),COLORYELLOW;
大资金:(CT=0 AND X_63 AND COUNT(X_63,50)=1)*85,STICK,COLORYELLOW;
X_64:=MA(VOL,5)>MA(VOL,60);
介入:IF(X_33<0.15 AND ABS(X_33-X_34)<0.05 AND CROSS(X_33,X_34) AND X_64,1,0)*80,STICK,COLORRED,LINETHICK2;
X_65:=FILTER(介入,16);
X_66:=27;
DRAWTEXT(X_65,IF(介入>0 AND X_6<8,60,70),X_66),COLORYELLOW;
X_67:=EMA(CLOSE,12)-EMA(CLOSE,26);
X_68:=EMA(X_67,9);
CLOSE>60 AND CLOSE<100;
500;
X_69:=300;
X_70:=IF(CLOSE<40 AND CLOSE<=60,800,X_69);
X_71:=IF(CLOSE>10 AND CLOSE<=25,1000,IF(CLOSE>25 AND CLOSE<40,1000,X_70));
X_72:=IF(CLOSE<5,5000,IF(CLOSE>=5 AND CLOSE<=10,3000,X_71));
X_73:=IF(CLOSE>=6000,5,X_72);
X_74:=IF(CLOSE>1000 AND CLOSE<6000,25,X_73);
MACD:(X_67-X_68)*X_74,COLORSTICK;
X_75:=X_25>35 AND X_25<65 AND X_25>MA(REF(X_25,5),5) AND CT=0 AND X_3=1 AND X_6<8;
X_76:=FILTER(X_75,32);
DRAWTEXT(X_76,X_25*1.01,28),COLORYELLOW,LINETHICK2;
X_77:=CROSS(X_31,X_32) AND X_31<30 AND X_2=1 AND X_7>0;
X_78:=CROSS(X_32,X_31) AND X_31>80 AND X_2=1 AND X_7>0 AND CH=0;
STICKLINE(FILTER(X_77=1,10)=1,0,70,10,0),COLORRED;
DRAWTEXT(FILTER(X_77=1,10)=1,60,29),COLORYELLOW;
DRAWTEXT(FILTER(X_78=1,5)=1,80,30),COLORYELLOW;
X_79:=MA(CLOSE,5);
X_80:=MA(CLOSE,65);
X_81:=MA(CLOSE,21);
X_82:=COUNT(X_81>X_80,10)=10;
X_83:=MAX(X_79,MAX(X_81,X_80));
X_84:=MIN(X_79,MIN(X_81,X_80));
X_85:=ABS(X_83/X_84-1)*100<=15;
X_86:=COUNT(MACD<0,10)=10;
X_87:=IF(X_82 AND X_85 AND X_86,5,0);
X_88:=X_7>0 AND 0+IF(CROSS(0.1,X_87) AND CROSS(MACD,0),8,0);
X_89:=31;
STICKLINE(FILTER(X_88=1,50)=1,0,30,10,0),COLORYELLOW;
DRAWTEXT(FILTER(X_88=1,50)=1,10,X_89),COLORYELLOW;
警戒:90,COLOR5AFF9E;
轴:0;
未来函数检测结果如下:
该公式包含未来函数:ZIG
该公式包含未来函数:TROUGH
该公式包含未来函数:TROUGHBARS
该公式包含未来函数:WINNER
该公式包含未来函数:DYNAINFO
解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式
原理解析:
如果TIME>93000 AND TIME<94500返回1否则返回0
如果TIME>93100 AND TIME<145500返回1否则返回0
如果TIME>100000 AND TIME<145500返回1否则返回0
如果TIME>140000 AND TIME<145500返回1否则返回0
如果TIME>142500 AND TIME<145500返回1否则返回0
X_6赋值:DYNAINFO(14)*100
X_7赋值:DYNAINFO(8)
X_8赋值:X_7=0的350过滤
当满足条件X_8时,在45和22位置书写文字
X_9赋值:IF(TROUGHBARS(3,16,1)=0 AND 最高价>最低价+0.04,3,0)
X_10:=ZIG(3,6)>REF(ZIG(3,6),1) AND REF(ZIG(3,6),1)<=REF(ZIG(3,6),2) AND REF(ZIG(3,6),2)<=REF(ZIG(3,6),3)
X_11:=ZIG(3,22)>REF(ZIG(3,22),1) AND REF(ZIG(3,22),1)<=REF(ZIG(3,22),2) AND REF(ZIG(3,22),2)<=REF(ZIG(3,22),3)
X_12:=ZIG(3,51)>REF(ZIG(3,51),1) AND REF(ZIG(3,51),1)<=REF(ZIG(3,51),2) AND REF(ZIG(3,51),2)<=REF(ZIG(3,51),3)
X_13:=ZIG(3,72)>REF(ZIG(3,72),1) AND REF(ZIG(3,72),1)<=REF(ZIG(3,72),2) AND REF(ZIG(3,72),2)<=REF(ZIG(3,72),3)
X_14:=X_9
X_15:=X_10+X_11+X_12+X_13
X_16:=ZIG(3,6)[=REF(ZIG(3,6),2) AND REF(ZIG(3,6),2)>=REF(ZIG(3,6),3)]
X_17:=ZIG(3,22)[=REF(ZIG(3,22),2) AND REF(ZIG(3,22),2)>=REF(ZIG(3,22),3)]
X_18:=ZIG(3,51)[=REF(ZIG(3,51),2) AND REF(ZIG(3,51),2)>=REF(ZIG(3,51),3)]
X_19:=ZIG(3,72)[=REF(ZIG(3,72),2) AND REF(ZIG(3,72),2)>=REF(ZIG(3,72),3)]
X_20:=X_16+X_17+X_18+X_19
X_21:=IF(X_20>0,(-500),0)
如果收盘价>1000返回X_21*100否则返回X_21
输出CT:0的X_22日累和 AND X_2=1
输出五指山:EMA((收盘价-55日内收盘价最低值)/(55日内收盘价最高值-55日内最低价最低值)*100,5),画洋红色
X_23:=7*SMA((收盘价-27日内最低价最低值)/(27日内最高价最高值-27日内最低价最低值)*30,4,1)-3*SMA(SMA((收盘价-27日内最低价最低值)/(27日内最高价最高值-27日内最低价最低值)*30,4,1),3,1)-SMA(SMA(SMA((收盘价-27日内最低价最低值)/(27日内最高价最高值-27日内最低价最低值)*30,4,1),3,1),2,1)
输出万泉河:EX_23的5日简单移动平均,3),画青色
X_24:=五指山
X_25:=万泉河
如果X_2=1 AND X_24>80 AND CT=1返回1否则返回0
X_27:=X_26=1的350过滤
X_28:=23
当满足条件X_27时,在45和X_28位置书写文字
X_29:=(收盘价-36日内最低价最低值)/(36日内最高价最高值-36日内最低价最低值)*100
X_29的3日[1日权重]移动平均
X_30的3日[1日权重]移动平均
X_31的3日[1日权重]移动平均
X_33:=EMA(收盘价计算的获利盘比例,10)
X_34:=EMA(收盘价计算的获利盘比例,34)
X_35:=收盘价的32日简单移动平均
X_36:=收盘价的12日简单移动平均
X_37:=X_34上穿X_33
X_38:=收盘价的1日简单移动平均
X_39:=X_35的2日简单移动平均
X_40:=(收盘价-60日内最低价最低值)/(60日内最高价最高值-60日内最低价最低值)*80
X_40的7日[1日权重]移动平均
X_42:=(最低价+最高价+收盘价)/3
X_43:=(X_42-X_42的14日简单移动平均)/(0.015*AVEDEV(X_42,14))
X_44:=100*(79日内最高价最高值-收盘价)/(79日内最高价最高值-79日内最低价最低值)
X_45:=(2*收盘价+最高价+最低价+开盘价)/5
X_46:=34日内最低价最低值
X_47:=34日内最高价最高值
X_48:=EMA((X_45-X_46)/(X_47-X_46)*100,13)
X_49:=IF(X_44=0 OR X_48>=90 OR X_43>(-250),100,X_44)
如果X_14>0 OR X_15>0返回35否则返回DRAWNULL
输出岸:(X_2=1 AND CT=0 AND X_48=100 OR X_2=1 AND CT=0 AND X_48>0 AND X_44>98 AND X_48<=13)*60,STICK,画洋红色
输出花:EMA(IF(X_25<15 AND X_4=1 AND 最低价<=30日内最低价最低值,SMA(最低价-1日前的最低价的绝对值,30,1)/SMA(最低价-1日前的最低价和0较大值,30,1),0),3)*25,STICK,画黄色, 线宽为3
X_50:=X_23上穿X_25
X_51:=X_24<35 AND X_24>3日前的X_24的3日简单移动平均 AND CT=0 AND X_3=1 AND X_6<8
如果X_50=1 AND X_51=1返回75否则返回0
X_52:=技的16过滤
当满足条件X_52时,在25和24位置书写文字
X_53:=ZIG(3,5)>REF(ZIG(3,5),1) AND REF(ZIG(3,5),1)<=REF(ZIG(3,5),2) AND REF(ZIG(3,5),2)<=REF(ZIG(3,5),3)
输出看涨:X_53=1
输出CH:0的看涨日累和 AND X_2=1
X_54:=看涨的16过滤
当满足条件X_54时,在30和25位置书写文字
X_55:=1日前的收盘价
X_56:=SMA(收盘价-X_55和0较大值,7,1)/SMA(收盘价-X_55的绝对值,7,1)*100
X_57:=SMA(收盘价-X_55和0较大值,13,1)/SMA(收盘价-X_55的绝对值,13,1)*100
X_58:=SMA(X_55-收盘价和0较大值,7,1)/SMA(收盘价-X_55的绝对值,7,1)*100
X_59:=SMA(X_55-收盘价和0较大值,13,1)/SMA(收盘价-X_55的绝对值,13,1)*100
X_60:=收盘价的有效数据周期数
输出波:(X_4=1 AND X_56<25 AND X_57<30 AND X_60>35)*3,COLORSTICK, 线宽为2
X_61:=100-3*SMA((收盘价-65日内最低价最低值)/(80日内最高价最高值-65日内最低价最低值)*100,20,1)+2*SMA(SMA((收盘价-65日内最低价最低值)/(80日内最高价最高值-65日内最低价最低值)*100,20,1),15,1)
X_62:=100-3*SMA((开盘价-65日内最低价最低值)/(80日内最高价最高值-65日内最低价最低值)*100,20,1)+2*SMA(SMA((开盘价-65日内最低价最低值)/(80日内最高价最高值-65日内最低价最低值)*100,20,1),15,1)
X_63:=X_61<1日前的X_62 AND 成交量>1日前的成交量 AND 收盘价>1日前的收盘价
DRAWTEXT(CT=0 AND X_63 AND 统计50日满足X_63的天数=1,75,26),画黄色
输出大资金:(CT=0 AND X_63 AND 统计50日满足X_63的天数=1)*85,STICK,画黄色
X_64:=成交量的5日简单移动平均>成交量的60日简单移动平均
输出介入:IF(X_33<0.15 AND X_33-X_34的绝对值<0.05 AND X_33上穿X_34 AND X_64,1,0)*80,STICK,画红色, 线宽为2
X_65:=介入的16过滤
X_66:=27
如果介入>0 AND X_6<8返回60否则返回70
X_67:=收盘价的12日指数移动平均-收盘价的26日指数移动平均
X_68:=X_67的9日指数移动平均
收盘价>60 AND 收盘价<100
500
X_69:=300
如果收盘价<40 AND 收盘价<=60返回800否则返回X_69
X_71:=IF(收盘价>10 AND 收盘价<=25,1000,IF(收盘价>25 AND 收盘价<40,1000,X_70))
X_72:=IF(收盘价<5,5000,IF(收盘价>=5 AND 收盘价<=10,3000,X_71))
如果收盘价>=6000返回5否则返回X_72
如果收盘价>1000 AND 收盘价<6000返回25否则返回X_73
输出MACD:(X_67-X_68)*X_74,COLORSTICK
X_75:=X_25>35 AND X_25<65 AND X_25>5日前的X_25的5日简单移动平均 AND CT=0 AND X_3=1 AND X_6<8
X_76:=X_75的32过滤
当满足条件X_76时,在X_25*1.01和28位置书写文字
X_77:=X_31上穿X_32 AND X_31<30 AND X_2=1 AND X_7>0
X_78:=X_32上穿X_31 AND X_31>80 AND X_2=1 AND X_7>0 AND CH=0
STICKLINE(X_77=1的10过滤=1,0,70,10,0),画红色
DRAWTEXT(X_77=1的10过滤=1,60,29),画黄色
DRAWTEXT(X_78=1的5过滤=1,80,30),画黄色
X_79:=收盘价的5日简单移动平均
X_80:=收盘价的65日简单移动平均
X_81:=收盘价的21日简单移动平均
X_82:=统计10日满足X_81>X_80的天数=10
X_83:=MAX(X_79,MAX(X_81,X_80))
X_84:=MIN(X_79,MIN(X_81,X_80))
X_85:=X_83/X_84-1的绝对值*100<=15
X_86:=统计10日满足MACD<0的天数=10
如果X_82 AND X_85 AND X_86返回5否则返回0
X_88:=X_7>0 AND 0+IF(0.1上穿X_87 AND MACD上穿0,8,0)
X_89:=31
STICKLINE(X_88=1的50过滤=1,0,30,10,0),画黄色
DRAWTEXT(X_88=1的50过滤=1,10,X_89),画黄色
输出警戒:90,COLOR5AFF9E
输出轴:0