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

RE: [amibroker] Performance Charts



PureBytes Links

Trading Reference Links

Hello,

I have run your code on the following stocks:
INTC (intel)
AA (alcoa)
C (citigroup)
IBM (intl. business machines)

And in all cases I get the same results of individual backtest vs explore.

Background:
Equity() funciton is an "OLD" backtester. It gives the same results as 
*individual backtest* provided that you do NOT use "Pad and align" option (found in AA-Settings->Portfolio tab)

Best regards,
Tomasz Janeczko
amibroker.com
----- Original Message ----- 
From: "vlanschot" <ecbu@xxxxxxxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Friday, May 14, 2004 10:37 AM
Subject: [amibroker] Help: different results Explore vs Individual Backtest


> Hello AB Community,
> 
> Perhaps somebody can help me with the following.
> 
> Below I have a simple example strategy which I run in both Explore 
> and Individual Backtest. You can use any group of securities yourself 
> to replicate. 
> 
> The problem is that I get different results in the Equity(1) (here: 
> IndivEq) via Explore versus the results shown in the Individual 
> Backtest. Differences amount to a couple of dollars to a few 
> thousand. So the question is: how can I make sure that I get the same 
> (equity) results in Explore and in the Individual Backtest.
> 
> No doubt there is a simple explanation here, but I can't figure it 
> out.
> 
> Thanks in advance for your help.
> 
> Patrick
> 
> Filter=1;
> 
> Groep=GroupID();
> List = GetCategorySymbols(categoryGroup,Groep);
> //SetBarsRequired(10,10); 
> 
> MPLB=126; //Daily
> AnnPer = 256;
>  
> for( n=1; (Ticker=StrExtract( List, n))!= ""; n++)
> {
> k=n+1;
> } 
> 
> //TypeBacktest=Status("action");
> Scan = Status("Action")==3;
> Indicator = Status("Action")==1;
> Explore = Status("Action")==4;
> Backtest = Status("Action")==5;
> 
> SetOption("InterestRate",0);
> SetOption("MaxOpenPositions",k);
> SetOption ("CommissionMode",1);
> CommPerc = Param("Commission%",1,0.25,5);
> SetOption("CommissionAmount", CommPerc);
> 
> WLScan = 0;
> if (Scan AND WLScan==1)// = Scan Mode for Next day's trades
> Delay = 0;
> else
> Delay = 1;
> 
> SetTradeDelays( Delay, Delay, Delay, Delay );
> 
> StartCapital = 1000000;
> 
> PFBT = 0;
> 
> if (Scan OR Explore OR (Backtest AND PFBT==0))
> SetOption("InitialEquity",StartCapital/k);
> else
> if (Backtest AND PFBT==1) SetOption("InitialEquity",StartCapital);
> 
> BarInTest=Status("barinrange");
> ValidB=//1;
> BarIntest==1;
> 
> Buy=ValidB AND MACD()>Signal() ; 
> Sell = ValidB AND Signal()>MACD(); 
> //Short = Sell; Cover = Buy; 
> Short=0; Cover = 0;
> 
> BuyPrice=SellPrice=ShortPrice=CoverPrice=Close;
> 
> SigEq=1;
> 
> IndivEq = Equity(SigEq); 
> AddToComposite( Indiveq, "~ComposEq", "C" );
> ComposEq = Foreign("~ComposEq","C");
> 
> PFBTCap = LastValue(ValueWhen(Status("firstbarinrange"),ComposEq));
> 
> if(Backtest AND PFBT==1)
>  
> PositionSize=
> //IndivEq;
> -IndivEq/ComposEq;
> //-100/k;
> else
> PositionSize=-100;
> 
> PositionScore = 
> //1;
> 100 - RSI(14);
> 
> AddColumn(Indiveq,"IndivEq", 1.3);
> AddColumn(ComposEq,"CompEq", 1.3);
> 
> 
> 
> 
> 
> 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 
> Yahoo! Groups Links
> 
> 
> 
>  
> 
> 


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/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 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
     http://groups.yahoo.com/group/amibroker/

<*> 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/