PureBytes Links
Trading Reference Links
|
Kyle,
You would need to use AddToComposite to scan the entire universe (say, of the NYSE) for advances and declines, and create two custom symbols: "~adv" (sum of all advances) and "~dec" (sum of all declies). You can change "~adv" and "~dec" as you wish.
Following the AddToComposite run, you can write a new AFL and access (using "Foreign") the three relevant symbols:
(i) "~adv"
(ii) "~dec"
(iii) "SPX" (S&P 500 Index)
Once these are accessed, you can easily program any trading idea and backtest/explore it.
Regards,
Amit Ehrenreich
Market Testing Wizards
www.markettestingwizards.com
________________________________
From: amibroker@xxxxxxxxxxxxxxx on behalf of smithkt9675
Sent: Sat 3/29/2008 10:42 PM
To: amibroker@xxxxxxxxxxxxxxx
Subject: [amibroker] Easy for experts
Here's the code:
Adv=Close>Ref(Close,-1);
Dec=Close<Ref(Close,-1);
CHADTP=(Sum(Adv,5)-Sum(Dec,5))/5;
How do I write a buy/sell signal with arrows. The signals I want
are:
When CHADTP > 400 and S&P 500 Close < S&P 500 Close Previous Day
+.10 = Sell
When CHADTp < 400 and S&P 500 Close > S&P 500 Close Previous Day -
.10 = Buy
This seems so simple to me...I'm just getting caught up. You have
to run CHADTP against all the constituents in the NYSE and you have
to reference the S&P 500 at the same time. How do you run the
scan/explore and simultaneously reference the foreign SPX to get
arrows on the SPX for trade signals?
Thanks in advance.
Kyle
------------------------------------
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 NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/
For other support material please check also:
http://www.amibroker.com/support.html
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/amibroker/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:amibroker-digest@xxxxxxxxxxxxxxx
mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx
<*> To unsubscribe from this group, send an email to:
amibroker-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
<<winmail.dat>>
|