dif_j:=ema(jgl_df,10),color1234aa,linethick2;{积分}
dea_g:=ema(dif_j,8),color338833,linethick2;{平滑}
macd_l:=(dif_j-dea_g)*10;
k_df:=sma(jgl_df,3,1)*1,colorfedcba;{以下为 类kdj }
d_df:=sma(k_df,3,1),color13f8f9;
j_df:=3*k_df-2*d_df,colorf813f9;
{以下显示 j_df前差值柱 ,柱子太薄时显示 十 字星}
rf:=ref(j_df,1);
dj:=abs(j_df-rf);
mm:=(hhv(dj,240)+llv(dj,240))/2;
stickline(macd ref(macd,1) and macd 0,0,macd,-1,0),colorred;
stickline(macd ref(macd,1) and macd 0,0,macd,-1,1),colorlired;
stickline(macd ref(macd,1) and macd 0,0,macd,-1,1),colorwhite;
stickline(macd ref(macd,1) and macd 0,0,macd,-1,0),colorcyan;
一级:(-2*ref(macd,2)+ref(macd,1)+2*macd);
{这是五点平滑二阶导数中心截断右半支,紧跟股价}
二级:(-0.4*ref(macd,4)-0.4*ref(macd,3)-1.1*ref(macd,2)+0.9*ref(macd,1)+2*macd);
{这是五点、九点平滑二阶导数中心截断右半支的平均值,紧跟股价}
三级:(-0.8*ref(macd,4)-0.8*ref(macd,3)-0.2*ref(macd,2)+0.8*ref(macd,1)+2*macd);
{这是九点平滑二阶导数中心截断右半支,紧跟股价};
日趋势:sma(sma(一级,9,1),9,1);
drawband(一级,rgb(200,10,10),三级,rgb(0,0,128));