Atas bantuan Pak Eko Widjajanto akhirnya afl untuk mengukur market breadth ini bisa jalan.. Sekalian memberikan ide pembuatan afl untuk McClellan Summation Indexnya.. Terima kasih Pak Eko yg sabar sama newbie 

Berikut step & aflnya..
1. Buat afl berikut :
AddToComposite( C > Ref( C, -1 ), "~StocksAdv", "X" );
AddToComposite( C < Ref( C, -1 ), "~StocksDec", "X" );
Buy=Sell=Short=Cover=0;
Filter=1;
AddToComposite( C < Ref( C, -1 ), "~StocksDec", "X" );
Buy=Sell=Short=Cover=0;
Filter=1;
2. Jalankan AA, dan jalankan scan untuk membuat symbol baru ~StocksAdv dan ~StocksDec
3. Buat afl baru berikut :
AddToComposite( C > Ref( C, -1 ), "~StocksAdv", "X" );
AddToComposite( C < Ref( C, -1 ), "~StocksDec", "X" );
AddToComposite( C == Ref( C, -1 ), "~StocksNC", "X" );
Adv = Foreign( "~StocksAdv", "X" );
Dec = Foreign( "~StocksDec", "X" );
NC = Foreign ( "~StocksNC", "X" );
AddToComposite( C < Ref( C, -1 ), "~StocksDec", "X" );
AddToComposite( C == Ref( C, -1 ), "~StocksNC", "X" );
Adv = Foreign( "~StocksAdv", "X" );
Dec = Foreign( "~StocksDec", "X" );
NC = Foreign ( "~StocksNC", "X" );
McClellanOsc = EMA( ( Adv - Dec ), 19 ) - EMA( ( Adv - Dec ), 39 );
Plot( McClellanOsc, "McClellanOsc", colorBlue, styleLine | styleNoTitle | styleThick );
Plot( McClellanOsc, "McClellanOsc", colorBlue, styleLine | styleNoTitle | styleThick );
_N( Title =
EncodeColor( colorGreen ) + "Advance Issues = " + WriteVal( Adv, 1.0 ) +
EncodeColor( colorRed ) + " Decline Issues = " + WriteVal( Dec, 1.0 ) + "\n" +
EncodeColor( colorBlue ) + "McClellan Oscillator = " + WriteVal( McClellanOsc, 1.2 ) );
EncodeColor( colorGreen ) + "Advance Issues = " + WriteVal( Adv, 1.0 ) +
EncodeColor( colorRed ) + " Decline Issues = " + WriteVal( Dec, 1.0 ) + "\n" +
EncodeColor( colorBlue ) + "McClellan Oscillator = " + WriteVal( McClellanOsc, 1.2 ) );
4. Oscillator selesai :D
Untuk membuat Summation Indexnya, tinggal mengganti baris McClellanOsc = EMA( ( Adv - Dec ), 19 ) - EMA( ( Adv - Dec ), 39 );
Menjadi McClellanOsc = Cum( EMA( ( Adv - Dec ), 19 ) - EMA( ( Adv - Dec ), 39 ) );
Untuk mengetahui penggunaan afl ini, silahkan lihat buku Tim Ord berjudul The Secret Science of Price and Volume bab 6
Terima kasih
From: Eko Widjajanto <ekow19d@gmail.com>
To: amibroker-4-bei@yahoogroups.com
Sent: Monday, September 17, 2012 6:01 PM
Subject: RE: [Komunitas AmiBroker] McClellan Oscillator untuk IDX
Kalau ada afl memakai Addtocomposite, misalnya : AddToComposite( C > Ref( C, -1 ), "~StocksAdv", "X" ); ,
maka ~StocksAdv baru akan diisi kalau kita jalankan afl-nya dengan klik Scan pada jendela AA.
Sebuah symbol baru, yaitu ~StockAdv akan dibuat oleh Amibroker lengkap dengan OHLC-nya. Silahkan baca Help atau bukunya Husni.
Setelah symbol ~StocksAdv ada isinya baru kemudian bisa dipakai dengan Foreign command , misalnya : Adv = Foreign( "~StocksAdv", "X" );
Silahkan coba.
From: amibroker-4-bei@yahoogroups.com [mailto:amibroker-4-bei@yahoogroups.com] On Behalf Of ramanattar
Sent: Saturday, September 15, 2012 9:22 PM
To: amibroker-4-bei@yahoogroups.com
Subject: [Komunitas AmiBroker] McClellan Oscillator untuk IDX
Sent: Saturday, September 15, 2012 9:22 PM
To: amibroker-4-bei@yahoogroups.com
Subject: [Komunitas AmiBroker] McClellan Oscillator untuk IDX
Selamat malam,
Mohon informasi afl untuk oscillator ini yang bisa digunakan di IDX, karena yg di Afl Library tidak bisa dipakai (hanya muncul garis lurus saja)
Berikut afl yang ada di Library
Graph0 = EMA( AdvIssues()-DecIssues(), 19 ) - EMA( AdvIssues()-DecIssues(), 39 );
Terima kasih
Mohon informasi afl untuk oscillator ini yang bisa digunakan di IDX, karena yg di Afl Library tidak bisa dipakai (hanya muncul garis lurus saja)
Berikut afl yang ada di Library
Graph0 = EMA( AdvIssues()-DecIssues(), 19 ) - EMA( AdvIssues()-DecIssues(), 39 );
Terima kasih
__._,_.___
Harga Software AmiBroker:
- Versi Professional: Rp 2,5 Jt
- Versi Standard: Rp 1,8 Jt
Harga Paket Realtime Intraday Data:
- 1 bulan Rp 250 Rb
- 3 bulan Rp 675 Rb (after disc 10%)
- 6 bulan Rp 1,2 Jt (after disc 20%)
- 12 bulan Rp 2,3 Jt (after disc 23%)
Pemesanan:
E-Mail: sales@integrity.co.id
Ph: 021-57936155
SMS: 08159304868
Pin: 285844A8
http://www.integrity.co.id
Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe
__,_._,___
No comments:
Post a Comment