您好,欢迎访问三七文档
当前位置:首页 > 金融/证券 > 综合/其它 > macd选股公式实例
以下公式适合通达信股票软件。选出股票后能否买入依然还要综合参考大趋势和其它指标。金叉并非万能,有时刚刚进入金叉或准金叉状态,也可能是上一波反弹的结束,下一波下跌的开始。只有当金叉周期的前后周期均为上涨趋势,金叉的威力才最大。业绩的持续增长才是技术指标的前提和保证。1、0轴上方第一次金叉选股公式:DIFF:=EMA(CLOSE,12)-EMA(CLOSE,26);DEA:=EMA(DIFF,9);MACD:=2*(DIFF-DEA);xg:cross(diff,dea)anddea-1.0anddea0.5andCLOSEref(CLOSE,1)andCLOSE=ma(c,60);或:DIF:=EMA(CLOSE,12)-EMA(CLOSE,26);DEA:=EMA(DIF,9);XG:DIF0ANDDEA0ANDCROSS(DIF,DEA);2、0轴上方二次金叉的选股公式:JC:IF(SUM(IF(MACD0ANDCROSS(MACD.DIF,MACD.DEA),1,0),0)-HHV(IF(IF(CROSS(MACD.DEA,0),1,0),SUM(IF(MACD0ANDCROSS(MACD.DIF,MACD.DEA),1,0),0),0),0)=2ANDSUM(IF(MACD0ANDCROSS(MACD.DIF,MACD.DEA),1,0),0)REF(SUM(IF(MACD0ANDCROSS(MACD.DIF,MACD.DEA),1,0),0),1),10,0);{选股设JC=10即可}3.0轴下方一次金叉的选股公式:DIFF:=EMA(CLOSE,12)-EMA(CLOSE,26);DEA:=EMA(DIFF,9);MACD:=(DIFF-DEA)*2;低位金叉:CROSS(DIFF,DEA)ANDDIFF-0.1;4、0轴下方二次金叉且第二次金叉高于第一次金叉:DIF:=EMA(CLOSE,12)-EMA(CLOSE,26);DEA:=EMA(DIF,9);AA:=BARSLAST(REF(CROSS(DIF,DEA),1));二次金叉:CROSS(DIF,DEA)ANDDIFREF(DIF,AA+1)ANDAA20ANDDIF0;5、0轴下方二次金叉选股公式:DIFF:=EMA(CLOSE,12)-EMA(CLOSE,26);{选股设JC=10即可}DEA:=EMA(DIFF,9);MACD:=2*(DIFF-DEA);A:=IF(CROSS(0,DEA),1,0);A1:=IF(DIFF0ANDCROSS(DIFF,DEA),1,0);SS:=IF(A,SUM(A1,0),0);SSB:=HHV(SS,0);SSS:=SUM(A1,0);JC:IF(SSS-SSB=2ANDSSSREF(SSS,1),10,0);6、缩量横盘突破选股:WH01:=(HHV(C,10)-LLV(C,10))/LLV(C,10)*100=10;WH02:=SUM(VOL,10)/CAPITAL*10045;WH03:=REF(WH01,1);WH04:=HHVBARS(HIGH,55)20ORC=HHV(H,55);WH05:=WH02ANDWH03ANDWH04ANDCREF(HHV(H,10),1);WH05ANDREF(NOT(WH05),1);7、均线、KDJ、MACD金叉的预警选股公式完全符合以下条件:1、5日线上穿10日线2、MACD金叉3、KDJ金叉(KDJ数值由9、3、3调整为8、2、2)4、成交量指标金叉通达信预警选股公式A1:=CROSS(MA(C,5),MA(C,10));A2:=CROSS(MACD.DIF,MACD.DEA);A3:=CROSS(KDJ.K(8,2,2),KDJ.D(8,2,2));A4:=CROSS(MA(V,5),MA(V,10));XG:A1ANDA2ANDA3AND4;三金叉选股完整源码,绝无未来函数均线、成交量、MACD同时金叉MA1:=MA(CLOSE,5);MA2:=MA(CLOSE,10);AA:=CROSS(MA1,MA2);AAA:=COUNT(AA,3)=1;T1:=MA(VOL,5);T2:=MA(VOL,10);BB:=CROSS(T1,T2);BBB:=COUNT(BB,3)=1;DIF:=EMA(CLOSE,12)-EMA(CLOSE,26);DEA:=EMA(DIF,9);MACD:=(DIF-DEA)*2;CC:=CROSS(DIF,DEA);CCC:=COUNT(CC,3)=1;三金:=AAAANDBBBANDCCC;三金叉:FILTER(三金,3),COLORFF00FF;使用说明:该选股公式适合超级短线,快进快出具有一定的风险因素,此时的股价往往处于拉高拔升阶段。要求使用者特别关注股价所处的位置,如果过于高位防止庄家诱多。低位可大胆搏杀,短期回档被套也有回旋余地。8、四线粘合N1:=5;N2:=10;N3:=20;M:=1;MA1:=MA(C,N1);MA2:=MA(C,N2);MA3:=MA(C,N3);A3:=VREF(V,1)*1.5ANDVMA(V,5);MAX(MA1,MAX(MA2,MA3))/MIN(MA1,MIN(MA2,MA3))1+0.01*MANDCOANDVREF(V,1)ANDFINANCE(7)=300000000ANDA3ANDCAPITAL=300000000;9、均线粘合M:=1;M5:=MA(CLOSE,5);M10:=MA(CLOSE,10);M20:=MA(CLOSE,20);K1:=MAX(MAX(M5,M10),MAX(M10,M20));K2:=MIN(MIN(M5,M10),MIN(M10,M20));A:=MAX(M5,MAX(M10,M20))/MIN(M5,MIN(M10,M20))1+0.01*M;A1:=(K1/K2-1)0.005;A2:=(K1/K2-1)0.005;A3:=VREF(V,1)*1.5ANDVMA(V,5);XG:AANDA1ANDA2ANDA3;10、多线粘合V0:=EMA(C,5);V1:=EMA(C,10);V2:=EMA(C,15);V3:=EMA(C,30);V4:=EMA(C,60);M1:=1000*V1/V4=1015AND1000*V1/V4=975;M2:=1000*V2/V4=1020AND1000*V2/V4=980;M3:=1000*V3/V4=1015AND1000*V3/V4=985;M4:=M1ANDM2ANDM3ANDCROSS(V0,V1);M5:=M1ANDM2ANDM3ANDCROSS(V0,V3);M4ORM5;11、MACD天天挣钱选股指标公式DIFF:=EMA(CLOSE,12)-EMA(CLOSE,26);DEA:=EMA(DIFF,9);XG:CROSS(REF(DEA,1),REF(DIFF,1))ANDCROSS(DIFF,DEA);12、短线之王VAR1:=(-100)*(HHV(HIGH,3)-CLOSE)/(HHV(HIGH,3)-LLV(LOW,3));CROSS(VAR1,-87)ANDOPENMA(CLOSE,5)ANDCLOSE=1.099*REF(CLOSE,1)ANDINDEXC0.98*REF(INDEXC,1)ANDCLOSE=1.47*LLV(CLOSE,58);13、自用短线MACD副图DIF:EMA(CLOSE,3)-EMA(CLOSE,7);DEA:EMA(DIF,3);MACD:(DIF),COLORSTICK;DIF,COLORGREEN,LINETHICK2;DEA,COLORGREEN,LINETHICK2;线上金叉买:0,COLORGREEN,LINETHICK2;IF(DIFDEA,DIF,DRAWNULL),COLORRED,LINETHICK2;IF(DEAREF(DEA,1),DEA,DRAWNULL),COLORMAGENTA,LINETHICK2;DRAWICON(CROSS(DIF,DEA),DEA,25);DRAWICON(CROSS(DEA,DIF),DEA,24);14、MACD底位反转点DIF:EMA(CLOSE,12)-EMA(CLOSE,135);DEA:=EMA(DIF,9);MACD:=(DIF-DEA)*2;反转:MACD0ANDMACDREF(MACD,1)ANDREF(MACD,1)REF(MACD,2)ANDREF(MACD,2)REF(MACD,3)ANDREF(MACD,3)REF(MACD,4);15.冠军MACD资金流向DIFF:=EMA(CLOSE,3)-EMA(CLOSE,7);DEA:=EMA(DIFF,3);MACD2:=2*(DIFF-DEA);(CLOSE0ANDCROSS(DIFF,0),H*1.3),COLOR000080,NODRAW;(CLOSE0ANDCROSS(MACD2,0),H*1.3),COLOR000080,NODRAW;(CLOSE0ANDCROSS(0,DIFF),H*1.3),COLOR808080,NODRAW;(CLOSE0ANDCROSS(0,MACD2),H*1.3),COLOR808080,NODRAW;DU0:=CROSS(DIFF,0);UD0:=CROSS(0,DIFF);TDU0:=BARSLAST(DU0);TUD0:=BARSLAST(UD0);DU3:=REF(DU0,1);UD3:=REF(UD0,1);TDU3:=BARSLAST(DU3);TUD3:=BARSLAST(UD3);UDGLINE:=IF(TDU3TUD3,REF(HHV(HIGH,2),TDU3),REF(LLV(LOW,2),TUD3));JDU0:=REF(CLOSE,1)=REF(UDGLINE,1)ANDCLOSEUDGLINEANDTDU0TUD0;JUD0:=REF(CLOSE,1)=REF(UDGLINE,1)ANDCLOSEUDGLINEANDTUD0TDU0;JDU1:=JDU0ANDCOUNT(JDU0,TDU0)=1;JUD1:=JUD0ANDCOUNT(JUD0,TUD0)=1;JDU2:=JDU1ANDREF(BARSLAST(JUD1),1)REF(BARSLAST(JDU1),1);JUD2:=JUD1ANDREF(BARSLAST(JUD1),1)REF(BARSLAST(JDU1),1);JDU3:=JDU1ANDREF(BARSLAST(JUD1),1)REF(BARSLAST(JDU1),1);JUD3:=JUD1ANDREF(BARSLAST(JUD1),1)REF(BARSLAST(JDU1),1);BSLINE:=IF(BARSLAST(JDU2)BARSLAST(JUD2),IF(REF(CROSS(0,MACD2),1),LLV(LOW,2),REF(LLV(LOW,2),BARSLAST(REF(CROSS(0,MACD2),1)))),IF(REF(CROSS(MACD2,0),1),HHV(HIGH,2),REF(HHV(HIGH,2),BARSLAST(REF(CROSS(MACD2,0),1)))));STICKLINE(MACD2=0,0,MACD2,2,1),COLOR0000FF;STICKLINE(MACD2=0ANDMACD2REF(MACD2,1),0,MACD2,2,0),COLOR0000FF;STICKLINE(MACD20,0,MACD2,2,0),COLORFFFF00;STICKLINE(MACD20ANDMACD2REF(MACD2,1),0,MACD2,2,1
本文标题:macd选股公式实例
链接地址:https://www.777doc.com/doc-7035642 .html