PureBytes Links
Trading Reference Links
|
I posted this earlier today on Amibroker-ts mailing list but
looking at the dates of the posts I think this list will get
a better response. I am new to AFL so I would appreciate some help
on the following system. (Still needs lots of work- inspired by an
article I read interviewing John Bollinger).
In words I would like to Short sell if
1. The price of a stock crossed the BBandTop(20,2)
2. The 20 Day Average OBV was negative
3. The stock closes lower three days after the cross.
4. Cover when the stock crosses the BBandBot(20,2)
The long selling is the oposite. Here is the code
Short = (Ref(H,-3) >= Ref(BBandTop(H,20,2),-3) AND Ref(MA(OBV(),20),-
3) < 0 AND H < Ref(H,-3));
Cover = Cross(C,BBandBot(C,20,2));
Buy = (Ref(H,-3) <= Ref(BBandBot(H,20,2),-3) AND Ref(MA(OBV(),20),-
3) > 0 AND H > Ref(H,-3));
Sell = Cross(C,BBandTop(C,20,2));
My question was basically- Is the code implementation correct? and
also I would like to set my stop loss points at the price
when the stock crossed the Bollinger Bands three days ago I was
looking at the ApplyStop Function but have not gotten anywhere.
I would also like to make sure I buy on the Opening the following
day. Thanks for any help. Marc
Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
|