{"id":1089,"date":"2015-01-30T15:38:27","date_gmt":"2015-01-30T20:38:27","guid":{"rendered":"http:\/\/www.amibroker.com\/kb\/?p=1089"},"modified":"2015-02-11T18:43:53","modified_gmt":"2015-02-11T23:43:53","slug":"how-to-use-custom-backtest-metric-as-an-optimization-target","status":"publish","type":"post","link":"https:\/\/www.amibroker.com\/wordpress\/kb\/2015\/01\/30\/how-to-use-custom-backtest-metric-as-an-optimization-target\/","title":{"rendered":"How to use custom backtest metric as an optimization target"},"content":{"rendered":"

In Optimization and Walk Forward testing AmiBroker allows us to choose the optimization target that determines optimum values of optimized parameters. This can be done in Analysis->Settings->Walk Forward<\/strong> tab and the drop down list contains a list of built-in statistics to choose from:<\/p>

\"Walk<\/p>

However, we are not limited to built-in metrics only. Custom Backtester Interface allows us to add any custom statistics to the backtest\/optimization reports and we can use these metrics for optimization too.<\/p>

To do that, we first need to add a custom metric (this article explains how to do it: http:\/\/www.amibroker.com\/guide\/a_custommetrics.html<\/a>). Then – we need to type-in<\/strong> our metric name into the Optimization Target box:<\/p>

\"Walk<\/p>

The name we enter must be an exact match of the metric name<\/strong> we have defined in AddCustomMetric() method. If entered name can not be found in the Optimization result table, then Net Profit will be used instead.<\/p>","protected":false},"excerpt":{"rendered":"

In Optimization and Walk Forward testing AmiBroker allows us to choose the optimization target that determines optimum values of optimized parameters. This can be done in Analysis->Settings->Walk Forward tab and the drop down list contains a list of built-in statistics to choose from:However, we are not limited to built-in metrics only. Custom Backtester Interface allows […]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[8],"tags":[],"_links":{"self":[{"href":"https:\/\/www.amibroker.com\/wordpress\/kb\/wp-json\/wp\/v2\/posts\/1089"}],"collection":[{"href":"https:\/\/www.amibroker.com\/wordpress\/kb\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.amibroker.com\/wordpress\/kb\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.amibroker.com\/wordpress\/kb\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.amibroker.com\/wordpress\/kb\/wp-json\/wp\/v2\/comments?post=1089"}],"version-history":[{"count":1,"href":"https:\/\/www.amibroker.com\/wordpress\/kb\/wp-json\/wp\/v2\/posts\/1089\/revisions"}],"predecessor-version":[{"id":1092,"href":"https:\/\/www.amibroker.com\/wordpress\/kb\/wp-json\/wp\/v2\/posts\/1089\/revisions\/1092"}],"wp:attachment":[{"href":"https:\/\/www.amibroker.com\/wordpress\/kb\/wp-json\/wp\/v2\/media?parent=1089"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.amibroker.com\/wordpress\/kb\/wp-json\/wp\/v2\/categories?post=1089"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.amibroker.com\/wordpress\/kb\/wp-json\/wp\/v2\/tags?post=1089"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}