PureBytes Links
Trading Reference Links
|
Osgem,
You have a typo in your last line of code (missing a quote mark in front
of the "I"). It then runs just fine.
Graph0 = Foreign( "~MyIndex", "C" )/Foreign( "~MyIndex", "I" );
Regards,
Gordon Sutherland
-----Original Message-----
From: amibroker@xxxxxxxxxxxxxxx [mailto:amibroker@xxxxxxxxxxxxxxx] On
Behalf Of osgem_2006
Sent: Friday, 25 August 2006 2:12 a.m.
To: amibroker@xxxxxxxxxxxxxxx
Subject: [amibroker] AddToComposite
I tried to create a composite by using following ATC formula and run a
scan against a watchlist but I get price chart of the 'first symbol'
on the list & not the composite value of the watchlist.what change is
needed to get a composite, the formula is as following.
/* AddToComposite statements are for Automatic Analysis -> Scan */
/* add Close price to our index OHLC fields */
AddToComposite(Close, "~MyIndex", "X" );
/* add one to open intest field (we use this field as a counter) */
AddToComposite( 1, "~MyIndex", "I" );
Buy = 0; // required by scan mode
/* this part is for Indicator Builder */
Graph0 = Foreign( "~MyIndex", "C" )/Foreign( "~MyIndex", I" );
any help would be appreciated.
thanks
Osgem
Please note that this group is for discussion between users only.
To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com
For other support material please check also:
http://www.amibroker.com/support.html
Yahoo! Groups Links
|