Bert,

I have not run any tests to confirm. But, based on your description, my guess 
would be that AmiBroker falls back to the default target when the specified 
target could not be found.

If all of the above is true, then a runtime error would probably have been more 
helpful since, as you've pointed out, the results would be very misleading.

Mike

--- In amibroker@yahoogroups.com, "bistrader" <bistra...@...> wrote:
>
> Mike,
> 
> I now understand via Tomasz and your replies.  Yet, I tried without custom 
> backtester code and by that I means that I typed CAR*(100 - abs(MDD)) under 
> Setting/Optimization Target.  AmiBroker's walkforward ran just fine with no 
> error, yet I am now, after the fact, guessing that the results are 
> meaningless.  I will do a little test to make sure.
> 
> Thanks
> 
> Bert
> 
> --- In amibroker@yahoogroups.com, "Mike" <sfclimbers@> wrote:
> >
> > Bert,
> > 
> > I believe that your understanding is correct in that you must create a 
> > custom metric to use anything other than the "out of the box" metrics 
> > provided by AmiBroker.
> > 
> > However, you must provide the name of the custom metric (case sensitive) as 
> > the optimization target, not the mathematical formula.
> > 
> > In your example you would need to enter CARTimes100LessMdd as the 
> > optimization target in the settings (i.e. the same value passed as the 
> > Title argument to bo.addcustommetric).
> > 
> > Mike
> > 
> > --- In amibroker@yahoogroups.com, "bistrader" <bistrader@> wrote:
> > >
> > > Mike and others,
> > > 
> > > Using this example, I would type the following as the "Optimization 
> > > target".
> > > 
> > > CAR*(100 - abs(MDD))
> > > 
> > > Yet, if I want to see these values in the walk forward stats, don't I 
> > > have to add something like the following to the end of the afl?  Or, is 
> > > there some way to tell AmiBroker to also list the "Optimization target" 
> > > without getting into the Custom Backtester?
> > > 
> > > SetCustomBacktestProc("");
> > > 
> > > if (Status("action") == actionPortfolio)
> > > {
> > >         bo = GetBacktesterObject();
> > > 
> > >         bo.backtest();
> > > 
> > >         st = bo.getperformancestats(0);
> > > 
> > >         CARTimes100LessMdd = st.getvalue("CAR") * ( 100 - 
> > > abs(st.getvalue("MaxSystemDrawdownPercent")) );
> > > 
> > >         bo.addcustommetric("CARTimes100LessMdd", CARTimes100LessMdd);
> > > }
> > > 
> > > Thanks
> > > 
> > > Bert
> > > 
> > > --- In amibroker@yahoogroups.com, "Mike" <sfclimbers@> wrote:
> > > >
> > > > Go to the Automatic Analysis window, click on the Settings... button, 
> > > > change to the Walk Forward tab, change the value for "Optimization 
> > > > target".
> > > > 
> > > > Mike
> > > > 
> > > > --- In amibroker@yahoogroups.com, "DougOriard" <doug@> wrote:
> > > > >
> > > > > When running one of the genetic optimizers, like cmae or trib, is it 
> > > > > possible to change the optimization target from CAR/MDD to just % 
> > > > > profit, or other target value?  
> > > > > 
> > > > > CAR/MDD is too heavily biased on minimizing MDD.  It would be better 
> > > > > to optimize for CAR*(100 - MDD), where MDD is taken as absolute value.
> > > > > 
> > > > > Is there a way to do this?
> > > > >
> > > >
> > >
> >
>


Reply via email to