Hi again!

Any ideas about following message?

PS I forgot that text editor would not accept greek characters when  writing 
first mail. Therefore every "O" symbol in the previous message means in fact 
greek "sigma" - a math symbol for a sum. Sorry for the inconvinience.


--- In [email protected], "tf28373" <tom...@...> wrote:
>
> 
> Hi!
> 
> I've been trying to add custom metric to backtester and optimization
> funcionalities called AIRAP
> <http://www.futures.pl/res_tmp/Hedge%20Quest%20-%20Summer%202005.pdf>  
> (Alternative Investment Risk Adjusted Performance), which is composed as
> follows:
> 
> AIRAP = [  Ó (( 1 +   TRi ) ^ (-3))/N ] ^ ( -1/3 ) -1, where  TRi  is
> i-th trade profit and N is number of trades.
> 
> I've come to following code:
> 
> SetCustomBacktestProc("");//AIRAP
> 
> if(Status("action")==actionPortfolio)
> 
> {bo=GetBacktesterObject();
> 
> bo.Backtest();
> 
> st=bo.GetPerformanceStats(0);
> 
> airap=
> 
> ((1+st.GetValue("NetProfit")^(-3))
> 
> /st.GetValue("AllQty")
> 
> )^(1/(-3))-1;
> 
> bo.AddCustomMetric("AIRAP",airap);}
> 
> However I don't know how to include the sum of this equation part: (( 1
> +   TRi ) ^ (-3))/N , in other word I cannot implement "Ó". I've been
> trying to achieve that using <sum()> function, without success though.
> 
> Can you show me some way to transcript AIRAP equation into AFL? Maybe
> there is some part of User Guide dealing with this issue which I've
> overlooked or some papers on that in Knowledge Base?
> 
> I will be grateful for any advice or trace :)
> 
> Regards
> 
> Tomasz
>


Reply via email to