按圖要求添加黃金分割代碼 [文華財(cái)經(jīng)]
-
咨詢內(nèi)容:
?
文件名:微信圖片_20210419232736.png
DIFF:= EMA(CLOSE,12) - EMA(CLOSE,26);//短周期與長(zhǎng)周期的收盤(pán)價(jià)的指數(shù)平滑移動(dòng)平均值做差。DEA:= EMA(DIFF,9);//DIFF的M個(gè)周期指數(shù)平滑移動(dòng)平均MACD:=2*(DIFF-DEA),COLORSTICK;//DIFF減DEA的2倍畫(huà)柱狀線J:=CROSS(DIFF,DEA);S:=CROSSDOWN(DIFF,DEA);LL:=CROSS( BACKSET(REFX(J,1)||ISLASTBAR&&DIFF<DEA,LLVBARS(L,BARSLAST(S)+1)+1),0.5),NODRAW;HH:=CROSS( BACKSET(REFX(S,1)||ISLASTBAR&&DIFF>DEA,HHVBARS(H,BARSLAST(J)+1)+1),0.5),NODRAW;DRAWLINE1(HH,H,LL,L,0),COLORGREEN,LINETHICK1;DRAWLINE1(LL,L,HH,H,0),COLORRED,LINETHICK1;?
?來(lái)源:程序化99
-
文華技術(shù)人員:
參考:
?
DIFF:= EMA(CLOSE,12) - EMA(CLOSE,26);//短周期與長(zhǎng)周期的收盤(pán)價(jià)的指數(shù)平滑移動(dòng)平均值做差。
DEA:= EMA(DIFF,9);//DIFF的M個(gè)周期指數(shù)平滑移動(dòng)平均
MACD:=2*(DIFF-DEA),COLORSTICK;//DIFF減DEA的2倍畫(huà)柱狀線
J:=CROSS(DIFF,DEA);
S:=CROSSDOWN(DIFF,DEA);
LL:=CROSS( BACKSET(REFX(J,1)||ISLASTBAR&&DIFF<DEA,LLVBARS(L,BARSLAST(S)+1)+1),0.5),NODRAW;
HH:=CROSS( BACKSET(REFX(S,1)||ISLASTBAR&&DIFF>DEA,HHVBARS(H,BARSLAST(J)+1)+1),0.5),NODRAW;
DRAWLINE1(HH,H,LL,L,0),COLORGREEN,LINETHICK1;
DRAWLINE1(LL,L,HH,H,0),COLORRED,LINETHICK1;
A:=BACKSET(ISLASTBAR,SUMBARS(HH||LL,2));
HHH:=REFX1(VALUEWHEN(HH,H),9999);
LLL:=REFX1(VALUEWHEN(LL,L),9999);
DRAWSL(A,HHH-0.382*(HHH-LLL),0,1,0,COLORRED);
DRAWSL(A,HHH-0.500*(HHH-LLL),0,1,0,COLORWHITE);
DRAWSL(A,HHH-0.618*(HHH-LLL),0,1,0,COLORGREEN);
DRAWNUMBER(CROSS(A,0.5),HHH-0.382*(HHH-LLL),HHH-0.382*(HHH-LLL),2,COLORRED),VALIGN2;
DRAWTEXT(CROSS(A,0.5),HHH-0.382*(HHH-LLL),'0.382'),COLORRED,VALIGN0;
DRAWNUMBER(CROSS(A,0.5),HHH-0.500*(HHH-LLL),HHH-0.382*(HHH-LLL),2,COLORWHITE),VALIGN2;
DRAWTEXT(CROSS(A,0.5),HHH-0.500*(HHH-LLL),'0.382'),COLORWHITE,VALIGN0;
DRAWNUMBER(CROSS(A,0.5),HHH-0.618*(HHH-LLL),HHH-0.382*(HHH-LLL),2,COLORGREEN),VALIGN2;
DRAWTEXT(CROSS(A,0.5),HHH-0.618*(HHH-LLL),'0.382'),COLORGREEN,VALIGN0;?
?來(lái)源: www.kzuj.com.cn
-
文華客服:
?數(shù)字顯示不對(duì)? ?都是0.382? ?重新幫我修改一下? ?謝謝
?
-
網(wǎng)友回復(fù):
?
參考:
?
DIFF:= EMA(CLOSE,12) - EMA(CLOSE,26);//短周期與長(zhǎng)周期的收盤(pán)價(jià)的指數(shù)平滑移動(dòng)平均值做差。
?
DEA:= EMA(DIFF,9);//DIFF的M個(gè)周期指數(shù)平滑移動(dòng)平均
MACD:=2*(DIFF-DEA),COLORSTICK;//DIFF減DEA的2倍畫(huà)柱狀線
J:=CROSS(DIFF,DEA);
S:=CROSSDOWN(DIFF,DEA);
LL:=CROSS( BACKSET(REFX(J,1)||ISLASTBAR&&DIFF<DEA,LLVBARS(L,BARSLAST(S)+1)+1),0.5),NODRAW;
HH:=CROSS( BACKSET(REFX(S,1)||ISLASTBAR&&DIFF>DEA,HHVBARS(H,BARSLAST(J)+1)+1),0.5),NODRAW;
DRAWLINE1(HH,H,LL,L,0),COLORGREEN,LINETHICK1;
DRAWLINE1(LL,L,HH,H,0),COLORRED,LINETHICK1;
A:=BACKSET(ISLASTBAR,SUMBARS(HH||LL,2));
HHH:=REFX1(VALUEWHEN(HH,H),9999);
LLL:=REFX1(VALUEWHEN(LL,L),9999);
DRAWSL(A,HHH-0.382*(HHH-LLL),0,1,0,COLORRED);
DRAWSL(A,HHH-0.500*(HHH-LLL),0,1,0,COLORWHITE);
DRAWSL(A,HHH-0.618*(HHH-LLL),0,1,0,COLORGREEN);
DRAWNUMBER(CROSS(A,0.5),HHH-0.382*(HHH-LLL),HHH-0.382*(HHH-LLL),2,COLORRED),VALIGN2;
DRAWTEXT(CROSS(A,0.5),HHH-0.382*(HHH-LLL),'0.382'),COLORRED,VALIGN0;
DRAWNUMBER(CROSS(A,0.5),HHH-0.500*(HHH-LLL),HHH-0.382*(HHH-LLL),2,COLORWHITE),VALIGN2;
DRAWTEXT(CROSS(A,0.5),HHH-0.500*(HHH-LLL),'0.500),COLORWHITE,VALIGN0;
DRAWNUMBER(CROSS(A,0.5),HHH-0.618*(HHH-LLL),HHH-0.382*(HHH-LLL),2,COLORGREEN),VALIGN2;
DRAWTEXT(CROSS(A,0.5),HHH-0.618*(HHH-LLL),'0.618),COLORGREEN,VALIGN0;?
-
網(wǎng)友回復(fù):
?第17行無(wú)法識(shí)別
有思路,想編寫(xiě)各種指標(biāo)公式,交易模型,選股公式,還原公式的朋友
可聯(lián)系技術(shù)人員 QQ: 262069696 或微信號(hào):cxh99cxh99 進(jìn)行 有償收費(fèi) 編寫(xiě)!
(怎么收費(fèi),代編流程等詳情請(qǐng)點(diǎn)擊閱讀!)
(注:由于人數(shù)限制,QQ或微信請(qǐng)選擇方便的一個(gè)聯(lián)系我們就行,加好友時(shí)請(qǐng)簡(jiǎn)單備注下您的需求,否則無(wú)法通過(guò)。謝謝您!)
相關(guān)文章
-
沒(méi)有相關(guān)內(nèi)容