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

Re: [investment] Re: [amibroker] Re: Coding Question



PureBytes Links

Trading Reference Links

Dimitris,

Equity is single-security backtester.
Steve is referring to portfolio backtesting.

Best regards,
Tomasz Janeczko
amibroker.com
----- Original Message ----- 
From: "DIMITRIS TSOKAKIS" <TSOKAKIS@xxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Wednesday, October 08, 2003 12:25 PM
Subject: [investment] Re: [amibroker] Re: Coding Question


Steve,
I think Equity() does not accept variable From/To in
Equity(0,3,d1,d2)
I´m not sure for this.
Dimitris Tsokakis
--- In amibroker@xxxxxxxxxxxxxxx, "Steve Almond" <steve2@xxxx> wrote:
> Tomasz,
>
> The problem was that I could never QUITE get the expected result
using the formulae in PT. (and hence I don't yet want to 'translate'
this to Rotational trading in AB).
> One of the problems is that I don't know how to specify (using
AB/AA, not PT) a 250 day backtest completed on (say) 9/15/2001. (a
250 day backtest ending today is obvious, but not ending at some
previous date)
> Can you help with this?
> I can then do some manual checks on the PT code before moving it
over to AB Rotational.
>
> Thanks,
>
> Steve
>
>
>   ----- Original Message ----- 
>   From: Tomasz Janeczko
>   To: amibroker@xxxxxxxxxxxxxxx
>   Sent: Wednesday, October 08, 2003 09:53
>   Subject: [investment] Re: [amibroker] Re: Coding Question
>
>
>   Steve,
>
>   Wouldn't be enough just to enable rotational trading and adding
>   PositionScore = rScore;
>
>   assignment ?
>
>   Best regards,
>   Tomasz Janeczko
>   amibroker.com
>     ----- Original Message ----- 
>     From: Steve Almond
>     To: amibroker@xxxxxxxxxxxxxxx
>     Sent: Wednesday, October 08, 2003 10:37 AM
>     Subject: [amibroker] Re: Coding Question
>
>
>     Dimitris,
>
>     Thanks for the suggestion, but the skill needed to adapt your
application to mine is beyond me.
>     When I asked this question over on the PT board some time ago,
Bruce, Fred & Chuck came up with the following (for use in PT):
>
>     For Market Timing
>     RUT = Foreign("^RUT", "C");
>
>     UpTrend = EMA(RUT, 4) > EMA(RUT, 11);
>
>
>
>     For Scoring
>
>     Factor1 = IIf(UpTrend, C / Ref(C, -1), 1);
>
>     Factor2 = IIf(IsEmpty(Factor1), 1, Factor1);
>
>     STARTEQ = 1000;
>
>     Product = exp(Cum(log(Factor2))) * STARTEQ;
>
>     Score = Product / Ref(Product, -250);
>
>     rScore = IIf(IsEmpty(Score),0,IIf(Uptrend,Score,0));
>
>
>
>     Does this give any clue for running a similar system under AB's
new backtester?
>
>
>
>     Thanks,
>
>     Steve
>
>
>       ----- Original Message ----- 
>       From: DIMITRIS TSOKAKIS
>       To: amibroker@xxxxxxxxxxxxxxx
>       Sent: Monday, October 06, 2003 10:38
>       Subject: [investment] [amibroker] Re: Coding Question
>
>
>       Steve,
>       I have posted "A complete top10 application", Sept7, where I
take the
>       top10 performers of systemA and see their performance in
systemB.
>       See if it helps, else we shall create a solution from the
beginning.
>       Dimitris Tsokakis
>       --- In amibroker@xxxxxxxxxxxxxxx, "Steve Almond"
<steve2@xxxx> wrote:
>       > 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 = Foreign("^RUT", "C");
>       >     UpTrend = EMA(RUT, 4) > 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 = Foreign("^RUT", "C");
>       >     UpTrend = EMA(RUT, 4) > 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
>
>
>
>       Send BUG REPORTS to bugs@xxxx
>       Send SUGGESTIONS to suggest@xxxx
>       -----------------------------------------
>       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.
>
>
>
>     Send BUG REPORTS to bugs@xxxx
>     Send SUGGESTIONS to suggest@xxxx
>     -----------------------------------------
>     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.
>
>
>         Yahoo! Groups Sponsor
>               ADVERTISEMENT
>
>
>
>
>   Send BUG REPORTS to bugs@xxxx
>   Send SUGGESTIONS to suggest@xxxx
>   -----------------------------------------
>   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.



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/




------------------------ Yahoo! Groups Sponsor ---------------------~-->
Rent DVDs Online - Over 14,500 titles.
No Late Fees & Free Shipping.
Try Netflix for FREE!
http://us.click.yahoo.com/JYdFFC/XP.FAA/ySSFAA/GHeqlB/TM
---------------------------------------------------------------------~->

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/