【如何在Amibroker編寫Acceleration Oscillator 這指標】

2015-08-04 at 04:54:15

1)開啟formula editor

(按圖可放大)

AO 1

 

2)將以下copy到formula editor

 

AO 2

_SECTION_BEGIN(“ACCELERATION OSCILLATOR");

MAAvg34 = MA(Avg, 34);
MAAvg5 = MA(Avg, 5);
MADiff = MAAvg5 – MAAvg34;
AO = MA(MADiff – MA(MADiff, 5), 5);
ACUpBar = AO > Ref(AO, -1);
ACDownBar = AO < Ref(AO, -1);

Plot(AO,"AO",IIf(ACUpBar,colorGreen,colorRed),styleHistogram|styleThick);
Plot(0,"",15);

_SECTION_END();

 

 

3) 儲存在custom的file

AO 3

 

4) right click 指標按insert 便能將指標放在圖表上分析

AO 4

 

AO5

 

富昌金融集團聯席董事麥振威

電郵: paul.mark881@gmail.com