通达信主图指标股票实盘炒股黑马买点卖点出现公式源码
N:=12;M:=26;
DIFF:=EMA(C,N)-EMA(C,M);
DEA:=EMA(DIFF,9);
MA(C,8);
MA(C,21);
多头:STICKLINE(DIFF>DEA,C,O,3,-1),COLORRED;
STICKLINE(DIFF>DEA,H,L,0,0);
空头:STICKLINE(DIFF<=DEA,C,O,3,0);
STICKLINE(DIFF<=DEA,H,L,0,0);
DRAWTEXT(CROSS(DIFF,DEA),L*0.98,'买点出现');
DRAWTEXT(CROSS(DEA,DIFF),H*1.02,'卖点出现'),COLORGREEN;
DIFF1:=EMA(C,12)-EMA(C,26);
DEA1:=EMA(DIFF1,9);
MA(C,8);
MA(C,21);
多头1:STICKLINE(DIFF1>DEA1,C,O,3,0),COLORRED;
STICKLINE(DIFF>DEA1,H,L,0,0),COLORRED;
空头1:STICKLINE(DIFF1<=DEA1,C,O,3,0);
STICKLINE(DIFF1<=DEA1,H,L,0,0);
DRAWTEXT(CROSS(DIFF1,DEA1),L*0.98,'买点出现');
DRAWTEXT(CROSS(DEA1,DIFF1),H*1.02,'卖点出现'),COLORGREEN;
赞 (0)