当前位置: 网站首页 > 股票软件公式 > 同花顺公式 > 文章 当前位置: 同花顺公式 > 文章

同花顺源码精选:买卖早提示严买宽卖,日线资金抄底,MACD美颜版

点击: 次    来源:顶尖财经    作者:股市狙击 - 小 + 大

1、买卖早提示严买宽卖

用于跌后买入,不适用于追高。

下跌建仓区提示股价相对低位,与择机下手、庄家拉升重叠时,买入佳。
择机下手、庄家拉升配合主力吸筹吸货高点效果最佳。
买卖配合神奇九转。
阶段建仓,整跌不用。
提示建仓可能早(还会跌),提示终点可能过早(还会涨)。
指标是死的,人是活的,股市是动态的。心态平和,不孤注一掷,赢在成功率。
 

N:=5;
VAR1:4*SMA((CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100,5,1)-
3*SMA(SMA((CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N)) *100,5,1),3.2,1),coloryellow,LINETHICK0;
■现价vs两月最高■:100*REF(CLOSE,0)/HHV(H,60),color32CD99,NODRAW;
五2折:0.52*HHV(H,60),colorred,NODRAW;
【55】:0.55*HHV(H,60),colorbrown,NODRAW;
六折:0.6*HHV(H,60),colorlired,NODRAW;
【63】:0.63*HHV(H,60),colorwhite,NODRAW;
七折:0.7*HHV(H,60),coloryellow,NODRAW;
【742】:0.742*HHV(H,60),colorgreen,NODRAW;
八折:0.8*HHV(H,60),colorblue,NODRAW;
VAR2:8,colorgreen,LINETHICK0;
拉: IF(CROSS(VAR1,VAR2),80,0),STICK,colormagenta,LINETHICK2;
备: IF(VAR1<=0,25,0),STICK,colorlired,LINETHICK2;
DRAWTEXT(CROSS(VAR1,VAR2),80,'↑'),colorred;
VARO5:=LLV(LOW,27);
VARO6:=HHV(HIGH,34);
VARO7:=EMA((CLOSE-VARO5)/(VARO6-VARO5)*4,4)*25;
买区: IF((VARO7<10),80,100) ,COLOR00CCFF,LINETHICK1;
0,LINETHICK2 ,COLORFFCC00;
DRAWTEXT(VAR1<2.5,VAR1,'ō');
DRAWTEXT(VAR1>85 AND VAR1<=90,VAR1,'×'),colorwhite;
DRAWTEXT(VAR1>90,VAR1,'×'),colorgreen;
DRAWTEXT(REF(CLOSE,1)<=0.52*HHV(H,60),CLOSE,'↖'),colorred;
DRAWTEXT(REF(CLOSE,1)>0.52*HHV(H,60) AND REF(CLOSE,1)<=0.6*HHV(H,60),CLOSE,'↖'),colorbrown;
DRAWTEXT(REF(CLOSE,1)>0.6*HHV(H,60) AND REF(CLOSE,1)<=0.7*HHV(H,60),CLOSE,'↖'),coloryellow;
DRAWTEXT(REF(CLOSE,1)>0.7*HHV(H,60) AND REF(CLOSE,1)<=0.742*HHV(H,60),CLOSE,'↖'),colorgreen;
DRAWTEXT(REF(CLOSE,1)>0.742*HHV(H,60) AND REF(CLOSE,1)<=0.8*HHV(H,60),CLOSE,'↖'),colorblue;



2、日线资金抄底

下跌阶段看“手”就下手;震荡或向上阶段看“脸”下手,或股价已上涨。
( 股 民 学 院 : http://www.58188.net )
强势股【次新股第4坑可】看这张脸,普通股看▼底1PRO的脸。
手、脸对昨天,箭头对当天。
24-》25.99-》32.99
现价vs两月最高
 
IF(PERIODNAME<>"日线")
{
统计:"该指标只在日线周期下有效。";
RETURN;
}
■现vs高■:100*REF(CLOSE,0)/HHV(H,60),color32CD99,NODRAW;//现价vs两月最高
五2折:0.52*HHV(H,60),colorred,NODRAW;
【55】:0.55*HHV(H,60),colorbrown,NODRAW;
六折:0.6*HHV(H,60),colorlired,NODRAW;
【63】:0.63*HHV(H,60),colorwhite,NODRAW;
七折:0.7*HHV(H,60),coloryellow,NODRAW;
【742】:0.742*HHV(H,60),colorgreen,NODRAW;
八折:0.8*HHV(H,60),colorblue,NODRAW;
STICKLINE(■现vs高■>74.2 AND ■现vs高■<80,0,■现vs高■,8,0),colorblue;
STICKLINE(■现vs高■>70 AND ■现vs高■<=74.2,0,■现vs高■,8,0),colorgreen;
STICKLINE(■现vs高■>63 AND ■现vs高■<=70,0,■现vs高■,8,0),coloryellow;
STICKLINE(■现vs高■>60 AND ■现vs高■<=63,0,■现vs高■,8,0),colorwhite;
STICKLINE(■现vs高■>55 AND ■现vs高■<=60,0,■现vs高■,8,0),colorlired;
STICKLINE(■现vs高■>52 AND ■现vs高■<=55,0,■现vs高■,8,0),colorbrown;
STICKLINE(■现vs高■<=52,0,■现vs高■,8,0),colorred;
//大单净量
r:=((ZDMR[-1]+BDMR[-1])-(ZDMC[-1]+BDMC[-1]))/SHGZG*100;
//相对强弱
LC := REF(CLOSE,1);//前一日收盘价;
RSI$1:=SMA(MAX(CLOSE-LC,0),3,1)/SMA(ABS(CLOSE-LC),3,1)*100;
RSI$2:=SMA(MAX(CLOSE-LC,0),5,1)/SMA(ABS(CLOSE-LC),5,1)*100;
RSI$3:=SMA(MAX(CLOSE-LC,0),8,1)/SMA(ABS(CLOSE-LC),8,1)*100;
相对强弱:=0.5*RSI$1+0.31*RSI$2+0.19*RSI$3;
wave$1:=SMA(100*(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8)),3,1);
wave$2:=SMA(100*(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8)),5,1);
wave$3:=SMA(100*(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8)),8,1);
短线波段:=0.5*wave$1+0.31*wave$2+0.19*wave$3;
机会区:20,POINTDOT,colorred;
风险区:80,POINTDOT,colorgreen;
风险系数:0.5*相对强弱+0.5*短线波段,coloryellow;
//买入条件;
CD1:=IF(风险系数<20 AND CLOSE>OPEN AND r>0,1,0);//波段小于20,股价翻红;
CD2:=IF(风险系数<20 AND LOW>=REF(LOW,1) AND CLOSE>LOW AND r>0,1,0);//波段小于20,股价未翻红,但未创新低;
CD3:=IF(REF(风险系数,1)<20 AND 风险系数>REF(风险系数,1),1,0);//前一日波段小于20,今日转向;
SIGNALBUY=(CD1=1 OR CD2=1 OR CD3=1);
X=(SIGNALBUY AND COUNT(SIGNALBUY,3)=1);
DRAWICON(X,机会区,11);
//buy 2;
机会区xx:32.99,POINTDOT,colorwhite;//之前24,改为25.99,改为32.99
CDxx1:=IF(风险系数<32.99 AND 风险系数>=20 AND CLOSE>OPEN AND r>0,1,0);//波段小于20,股价翻红;
CDxx2:=IF(风险系数<32.99 AND 风险系数>=20 AND LOW>=REF(LOW,1) AND CLOSE>LOW AND r>0,1,0);//波段小于20,股价未翻红,但未创新低;
CDxx3:=IF(REF(风险系数,1)<32.99 AND REF(风险系数,1)>=20 AND 风险系数>REF(风险系数,1),1,0);//前一日波段小于20,今日转向;
SIGNALBUYxx=(CDxx1=1 OR CDxx2=1 OR CDxx3=1);
Xxx=(SIGNALBUYxx AND COUNT(SIGNALBUYxx,3)=1);
DRAWICON(Xxx,机会区xx,5);
 



3、MACD美颜版

DIFF:EMA(CLOSE,12)-EMA(CLOSE,26),LINETHICK1;
DEA:EMA(DIFF,9),COLOrffaa00,LINETHICK1;
MACD:=2*(DIFF-DEA);
STICKLINE(MACD>=0,MACD,0,4,1),colorred,LINETHICK3;
STICKLINE(MACD<REF(MACD,1)AND MACD>0,0,MACD,4,0 ),coloryellow,LINETHICK3;
STICKLINE(MACD<0,MACD,0,4,1),colorlired,LINETHICK3;
STICKLINE(MACD<0 AND MACD<REF(MACD,1),0,MACD,2,0),colorligreen,LINETHICK3;
X1:IF(diff<0,diff,0),COLOR0000FF,LINETHICK1;
X2:IF(diff<0,0,diff),colormagenta,LINETHICK1;
X3:IF(diff<dea,diff,dea),COLOR00ff00,linethick1;
X4:IF(diff>dea,dea,dea),linethick1,COLORffbb11;
低位金叉:=CROSS(DIFF,DEA) AND DIFF<-0.1;
STICKLINE(低位金叉,DEA*0.86,DEA*0.66,10,0),colormagenta;
DRAWTEXT(低位金叉,dea*0.96,' ↖【低位金叉】'),colormagenta;
WWW58188COM:=COUNT(CROSS(DIFF,DEA),BARSLAST(DEA>=0));
JCCOUNT:=COUNT(CROSS(DIFF,DEA),BARSLAST(DEA>=0));
二次金叉:=CROSS(DIFF,DEA) AND DEA<0 AND COUNT(JCCOUNT=2,21)=1;
STICKLINE(二次金叉,DEA*0.96,DEA*0.76,10,0),coloryellow;
DRAWICON(二次金叉,dea*1.1,'BUY') ;
DRAWTEXT(二次金叉,DEA*1.30,' ↖【二次金叉】'),coloryellow;
A1:=BARSLAST(REF(CROSS(DIFF,DEA),1));
底背离:=REF(CLOSE,A1+1)>CLOSE AND DIFF>REF(DIFF,A1+1) AND CROSS(DIFF,DEA);
STICKLINE(底背离,DEA*1.09,DEA*0.86,10,0),Color6600FF;
DRAWLINE(A1=0,DEA,底背离,DEA,0),colorred,linethick2;
DRAWTEXT(底背离,DEA*1.60,' ↖【多方炮台】'),Color6600FF;
A2:=BARSLAST(REF(CROSS(DEA,DIFF),1));
顶背离:=REF(CLOSE,A2+1)<CLOSE AND REF(DIFF,A2+1)>DIFF AND CROSS(DEA,DIFF);
DRAWLINE(A2=0 ,DEA,顶背离,REF(DEA,A2),0),colorligreen,LINETHICK2;
DRAWLINE(顶背离,DEA,顶背离,REF(DEA,A2),0),colorligreen,LINETHICK2;
DRAWTEXT(顶背离,DEA*1.2,' ↖【顶背离】'),Color00FF00;
FILLRGN(DIFF,DEA,DIFF>DEA AND DIFF>0 AND DIFF>REF(DIFF,1) AND DEA>REF(DEA,1),colormagenta);
FILLRGN(DIFF,DEA,DIFF>DEA AND DIFF>0 AND DIFF>REF(DIFF,1) AND DEA<REF(DEA,1),colorwhite);
FILLRGN(DIFF,DEA,DIFF>DEA AND DIFF>0 AND DIFF<=REF(DIFF,1) AND DEA>REF(DEA,1),colorwhite);
FILLRGN(DIFF,DEA,DIFF>DEA AND DIFF>0 AND DIFF<=REF(DIFF,1) AND DEA<REF(DEA,1),colorwhite);
FILLRGN(DIFF,DEA,DIFF>DEA AND DIFF<0 AND DIFF>REF(DIFF,1) AND DEA>REF(DEA,1),colorred);
FILLRGN(DIFF,DEA,DIFF>DEA AND DIFF<0 AND DIFF>REF(DIFF,1) AND DEA<REF(DEA,1),colorligray);
FILLRGN(DIFF,DEA,DIFF>DEA AND DIFF<0 AND DIFF<=REF(DIFF,1) AND DEA>REF(DEA,1),colorligray);
FILLRGN(DIFF,DEA,DIFF>DEA AND DIFF<0 AND DIFF<=REF(DIFF,1) AND DEA<REF(DEA,1),colorligray);
FILLRGN(DIFF,DEA,DIFF<DEA AND DIFF>0 AND DIFF<REF(DIFF,1) AND DEA>REF(DEA,1),colorligray);
FILLRGN(DIFF,DEA,DIFF<DEA AND DIFF>0 AND DIFF<REF(DIFF,1) AND DEA<REF(DEA,1),colorligreen);
FILLRGN(DIFF,DEA,DIFF<DEA AND DIFF>0 AND DIFF>=REF(DIFF,1) AND DEA>REF(DEA,1),colorlired);
FILLRGN(DIFF,DEA,DIFF<DEA AND DIFF>0 AND DIFF>=REF(DIFF,1) AND DEA<REF(DEA,1),colorlired);
FILLRGN(DIFF,DEA,DIFF<DEA AND DIFF<0 AND DIFF<REF(DIFF,1) AND DEA>REF(DEA,1),colorlired);
FILLRGN(DIFF,DEA,DIFF<DEA AND DIFF<0 AND DIFF<REF(DIFF,1) AND DEA<REF(DEA,1),colorgray);
FILLRGN(DIFF,DEA,DIFF<DEA AND DIFF<0 AND DIFF>=REF(DIFF,1) AND DEA>REF(DEA,1),colorlired);
FILLRGN(DIFF,DEA,DIFF<DEA AND DIFF<0 AND DIFF>=REF(DIFF,1) AND DEA<REF(DEA,1),colorlired);
FH1:=REF(MACD,1)<REF(MACD,2) AND REF(MACD,2)<REF(MACD,3) AND REF(MACD,3)<REF(MACD,4);
FH2:=MACD>=0 AND COUNT(MACD>REF(MACD,1),1)=1;
FH3:=FH1 AND FH2 AND EMA(C,13)>REF(EMA(C,13),1);
FH4:=FH1 AND FH2 AND ABS((DIFF-DEA)/C)<0.018;
FH5:=FH1 AND FH2 AND MACD<0.10;
二次翻红:(FH3 OR FH4 OR FH5),colorred,NODRAW;
低买:CROSS(DIFF,DEA) AND DIFF<0,COLORFF00FF,NODRAW;
DRAWICON(二次翻红,-0.05,1);
DRAWTEXT(二次翻红,-0.35,'↖【翻红】'),colorred;
DRAWTEXT_FIX(1,0.398,0.0388,0,'【股 民 学 院 : www.58188.net】'),colorcyan;

上一篇:同花顺源码精选:无极稳赚不赔,花神副图,分时买卖点超准

下一篇:同花顺源码精选:买卖点满意提示,最佳进场时机,主力中短组合