[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[amibroker] Coding Question



PureBytes Links

Trading Reference Links




I want to backtest a system (regular backtest, not rotational) 
which has the following two parts:
 
1. A simple market timing signal - let's say:
    
   RUT = <FONT 
color=#0000ff>Foreign("^RUT", <FONT 
color=#ff00ff>"C");
    UpTrend = <FONT 
color=#0000ff>EMA(RUT, 4) > <FONT 
color=#0000ff>EMA(RUT, 11);
 
2. A scoring system. I want the scoring system to be based on 
the 'performance' of the same market timing system.  Say on 12/31/1997 the 
market timing signal indicates a buy condition. I run a simple backtest of 1 
year duration on the 100 stocks in the Nasdaq100, like so:
 
    RUT = <FONT 
color=#0000ff>Foreign("^RUT", <FONT 
color=#ff00ff>"C");
    UpTrend = <FONT 
color=#0000ff>EMA(RUT, 4) > <FONT 
color=#0000ff>EMA(RUT, 11);
    buy=Uptrend;
    sell=NOT uptrend;
 
I pick the 5 best performing stocks (say highest CAR) and use 
them going forward into 1998, until the market timing signal gives a sell 
indication, when I sell the 5 stocks. At the next market timing buy signal, I 
again pick the top 5 performers (using the simple backtest) over the past year. 
etc. etc.
 
It seems like some sort of feedback system.
 
Is it possible?
 
Steve






Yahoo! Groups Sponsor


  ADVERTISEMENT 









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 the Yahoo! Terms of Service.