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

Re: [amibroker] Out of sample performance report is missing in Walk Forward Optimisation



PureBytes Links

Trading Reference Links

Zozu,

there is no report for a WF test in AB yet, and I hope that TJ will implement 
it soon. In the meantime you have to calculate the metrics by your own. You 
can use the following formula (I think it's from TJ):

Symbol = "~~~OSEQUITY"; // change the ticker to your preference 

eq = Foreign( "~~~OSEQUITY", "C" ); 

if( Name() != Symbol ) Title = "You should change symbol to " + Symbol; 

function TotalDays() 
{ 
yy = Year(); 
dy = DayOfYear(); 
LastLeapYear = (yy % 4) == 1 && yy != 2001; 
YearChg = yy != Ref(yy, -1); 
YearChg = IIf(IsNull(YearChg), False, YearChg); 
YearLen = IIf(YearChg, IIf(LastLeapYear, 366, 365), 0); 
return Cum(YearLen) + dy - dy[0]; 
} 

dr = 100 * ( eq/Highest(eq) - 1); 
profit = 100 * ( eq/eq[0] - 1 ); 

td = TotalDays(); 
Days = td[ BarCount - 1 ] - td[ 0 ]; 

Car = 100 * ( ( eq / eq[ 0 ] ) ^ ( 365 / Days ) - 1 ); 

Plot( dr, "DD%", colorRed ); 
Plot( Lowest(dr), "Max DD%", colorBlue ); 
Plot( profit, "Profit %", colorGreen ); 
Plot( Car, "CAR", colorDarkGreen ); 

Plot( Car/Highest( -dr ), "CAR/MDD", colorOrange );

In addition you can use TJ's code from 
http://www.amibroker.com/kb/2007/10/11/low-level-gfx-example-yearlymonthly-
profit-chart/ and replace 

eq = Foreign("~~~EQUITY", "C" );

with

eq = Foreign("~~~OSEQUITY", "C" );

HTH.

Thomas


On 14.07.2009, 13:24:36 zozuzoza wrote:
> Hi,
>
> It is possible to check the out of sample (OOS) equity by selecting the
> ~~~OSEQUITY ticker but I could not find the way of displaying the OOS
> performance report similar to backtest reports in report explorer. Did I
> miss something or this feature is not implemented in Amibroker?
>
> Thank you.
>
> Best regards,
> Zozu
>
>
>
> ------------------------------------
>
> **** IMPORTANT PLEASE READ ****
> This group is for the discussion between users only.
> This is *NOT* technical support channel.
>
> TO GET TECHNICAL SUPPORT send an e-mail directly to
> SUPPORT {at} amibroker.com
>
> TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
> http://www.amibroker.com/feedback/
> (submissions sent via other channels won't be considered)
>
> For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
> http://www.amibroker.com/devlog/
>
> Yahoo! Groups Links
>
>
>


------------------------------------

**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to 
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

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/