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

Re: [amibroker] Re: Possible Problem with Walk-Forward and Custom Metrics



PureBytes Links

Trading Reference Links

Hi,

I don't know if I'm out of subject, but I've seen what looks like a bug in the WFA process.   This is the second time it happens.  I do very long optimization (over 48 hours or more) and after some time (usually 24 hours or more) only the first parameters are chosen and the results are all identical. 

Anyone had the same problem?

Thanks,

Louis


2008/6/14 Joe <j0etr4der@xxxxxxxxx>:

Mike,

You are right, of course. Previously I was multiplying Sharpe and
KRatio and when I changed to adding them, I didn't remove that
unnecessary code. And I'd for some inexplicable reason changed
CompositeMetric * - 1 to Abs().

All fixed now. Thanks for pointing it out.

Joe



--- In amibroker@xxxxxxxxxxxxxxx, "Mike" <sfclimbers@xxx> wrote:
>
> Joe,
>
> Your code snippet does not make sense to me. If both NetProfitpc and
> RecFactor are negative, then ProfitMetric will never be positive
> (i.e. negative plus a negative equals a greater negative), and your
> condition will never be true.
>
> Thus, your _expression_ ProfitMetric = abs( ProfitMetric ); will never
> be evaluated and would have been redundant anyway, since you would
> only have executed it if you had found ProfitMetric to be positive in
> the first place and abs() just renders a negative number positive
> while having no affect on a positive number.
>
> Am I missing something?
>
> Mike
>
> --- In amibroker@xxxxxxxxxxxxxxx, "Joe" <j0etr4der@> wrote:
> >
> > If you are using a Custom Metric as your Optimization target in the
> > Walk-Forward settings, you should hand-check your results. I am
> > frequently getting incorrect results, in that the highest value of
> the
> > Custom Metric is not the one selected by W-F for a date range.
> >
> > I documented the problem in the 5.08beta to AB support on May 13th
> and
> > have not received a reply as yet.
> >
> > This is the metric that is currently causing(?) the problem:
> > [code snippet]
> > ProfitMetric = ( NetProfitpc + RecFactor * 20 ) * 10 ;//make them
> > ~equivalant
> > if( 0 > NetProfitpc AND 0 > RecFactor AND 0 <
> ProfitMetric )//if
> > both negative & result positive
> > ProfitMetric = abs( ProfitMetric );
> >
> > bo.AddCustomMetric( "Profit", ProfitMetric );
> > [end code snippet]
> >
> > Other of my metrics exhibit the same type of incorrect results in my
> > testing. I'm using Release 5.10.1 now, so I thought it was
> appropriate
> > to bring this to the attention of the group.
> >
> > Good trading,
> >
> > Joe
> >
>


__._,_.___

Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com

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

For other support material please check also:
http://www.amibroker.com/support.html




Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe

__,_._,___