以下是通达信更好盈利 副图源码(无源码的请下载附件导入)
通达信更好盈利 副图源码
均价:=(L+H+C*2)/4;
EMA14:=EMA(均价,14)COLORYELLOW,LINETHICK2;
涨跌率:(EMA14-REF(EMA14,1))/REF(EMA14,1)*100,,COLORWHITE,NODRAW;
上涨周期:=BARSLAST(CROSS(涨跌率,0));
收盘价:C,NODRAW;
买入止损:REF(均价,上涨周期),COLORGREEN,NODRAW;
买入:CROSS(C,买入止损),COLORRED,NODRAW;
STICKLINE(涨跌率>0,0,涨跌率*10,0.1,0),COLORRED;
STICKLINE(涨跌率<0,0,涨跌率*10,0.1,0),COLORCYAN;
STICKLINE(涨跌率>0 AND 涨跌率<REF(涨跌率,1),0,涨跌率*10,0.1,0),COLORLIGREEN;
STICKLINE(涨跌率<0 AND 涨跌率>REF(涨跌率,1),0,涨跌率*10,0.1,0),COLORLIRED;
MA5:=MA(C,6);
盈利:(均价-买入止损)/买入止损*100,,COLORYELLOW,LINETHICK2;
乖离:(均价-MA5)/MA5*100,COLORMAGENTA,LINETHICK2;
乖离均:MA(乖离,3)COLORGREEN,DOTLINE;
0,COLORGRAY,DOTLINE;
DRAWICON(买入=1,-1,1);
持股:IF(涨跌率>=0 {AND 涨跌率>REF(涨跌率,1)},0,DRAWNULL),COLORRED,LINETHICK1;
814377271.jpg
|